Revision 1b39b805

b/ChangeLog
1 1
===========
2
1.0.1 RELEASE
3
Minor fixes
4

  
5
Fixes:
6
	-Overview login theme
7
	-Add missing urls
8

  
9
===========
2 10
1.0.0 RELEASE
3 11
Major UI redesign, Debian Wheezy version, Django 1.4
4 12

  
b/README.txt
36 36
Installation Considerations
37 37
===========================
38 38

  
39
You can find the installation instructions for Ubuntu 12.04.3 (64)
40
with Django 1.3.x in install.txt file. FoD depends on a bunch of
41
packages. Installing in Debian Squeeze proved to be really tough as
42
the majority of the required packages are not provided by any repos
43
and need to be installed manually. This guide presents the
44
installation procedures for Ubuntu 12.04.3 (64) with Django 1.3.x.
45
Really soon, we will provide a guide for Debian Wheezy. However, users
46
who wish to go for Wheezy, need to read the Django 1.4 changelist. One
47
of the most significant changes in Django 1.4 is that the application
48
dir layout has to be restructured. Also bear in mind that Django 1.4
49
introduces new aspects when it comes to application library
50
inclussions.
51

  
52
Soon we will post a branch of FoD tailored for Django 1.4.
53

  
39
You can find the installation instructions for Debian Wheezy (64)
40
with Django 1.4.x at http://flowspy.readthedocs.org. 
41
If upgrading from a previous version bear in mind 
42
the changes introduced in Django 1.4. 
54 43

  
55 44
Contact
56 45
=======
......
58 47
You can find more about FoD or raise your issues at GRNET FoD
59 48
repository: https://code.grnet.gr/fod.
60 49

  
61
You can contactus directly at leopoul{at}noc[dot]grnet(.)gr
50
You can contact us directly at leopoul{at}noc[dot]grnet(.)gr
b/doc/source/conf.py
45 45
# built documents.
46 46
#
47 47
# The short X.Y version.
48
version = '1.0.0'
48
version = '1.0.1'
49 49
# The full version, including alpha/beta/rc tags.
50
release = '1.0.0'
50
release = '1.0.1'
51 51

  
52 52
# The language for content autogenerated by Sphinx. Refer to documentation
53 53
# for a list of supported languages.
b/flowspy/urls.py.dist
9 9
    # Example:
10 10
    (r'^poll/', include('poller.urls')),
11 11
    url(r'^/?$', 'flowspec.views.group_routes', name="group-routes"),
12
    url(r'^routes_ajax/?$', 'flowspec.views.group_routes_ajax', name="group-routes-ajax"),
13
    url(r'^overview_ajax/?$', 'flowspec.views.overview_routes_ajax', name="overview-ajax"),
14
    url(r'^dashboard/?$', 'flowspec.views.dashboard', name="dashboard"),
12 15
    url(r'^profile/?$', 'flowspec.views.user_profile', name="user-profile"),
13 16
    url(r'^add/?$', 'flowspec.views.add_route', name="add-route"),
14 17
    #url(r'^addrl/?$', 'flowspec.views.add_rate_limit', name="add-rate-limit"),
/dev/null
1

  
2
Installation
3
************
4

  
5

  
6
Ubuntu 12.04.3 (64) - Django 1.3.x
7
==================================
8

  
9
This guide assumes that installation is carried out in /srv/flowspy
10
directory. If other directory is to be used, please change the
11
corresponding configuration files. It is also assumed that the root
12
user will perform every action.
13

  
14

  
15
Required system packages
16
------------------------
17

  
18
Update and install the required packages:
19

  
20
   apt-get update
21
   apt-get upgrade
22
   apt-get install mysql-server apache2 memcached libapache2-mod-proxy-html gunicorn beanstalkd python-django python-django-extensions python-django-south python-django-tinymce tinymce python-mysqldb python-yaml python-memcache python-django-registration python-ipaddr python-lxml mysql-client git python-django-celery python-paramiko python-gevent vim
23

  
24
Note: Set username and password for mysql if used
25

  
26
Note: If you wish to deploy an outgoing mail server, now it is time to do
27
  it. Otherwise you could set FoD to send out mails via a third party
28
  account
29

  
30

  
31
Create a database
32
-----------------
33

  
34
If you are using mysql, you should create a database:
35

  
36
   mysql -u root -p -e 'create database fod'
37

  
38

  
39
Required application packages
40
-----------------------------
41

  
42
Get the required packages and install them
43

  
44
* ncclient: NETCONF python client:
45

  
46
     cd ~
47
     git clone https://github.com/leopoul/ncclient.git
48
     cd ncclient
49
     python setup.py install
50

  
51
* nxpy: Python Objects from/to XML proxy:
52

  
53
     cd ~
54
     git clone https://code.grnet.gr/git/nxpy
55
     cd nxpy
56
     python setup.py install
57

  
58
* flowspy: core application. Installation is done at /srv/flowspy:
59

  
60
     cd /srv
61
     git clone https://code.grnet.gr/git/flowspy
62
     cd flowspy
63

  
64

  
65
Application configuration
66
=========================
67

  
68
Copy settings.py.dist to settings.py:
69

  
70
   cp settings.py.dist settings.py
71

  
72
Edit settings.py file and set the following according to your
73
configuration:
74

  
75
   ADMINS: set your admin name and email (assuming that your server can send notifications)
76
   DATABASES (to point to your local database). You could use views instead of tables for models: peer, peercontacts, peernetworks. For this to work we suggest MySQL with MyISAM db engine
77
   SECRET_KEY : Make this unique, and don't share it with anybody
78
   STATIC_URL (static media directory) . If you have followed the above this should be: /srv/flowspy/static
79
   TEMPLATE_DIRS : If you have followed the above this should be: /srv/flowspy/templates
80
   CACHE_BACKEND:  If you have followed the above this should be: memcached://127.0.0.1:11211/?timeout=3600
81
   Alternatively you could go for redis with the corresponding Django client lib.
82
   NETCONF_DEVICE (tested with Juniper EX4200 but any BGP enabled Juniper should work). This is the flowspec capable device
83
   NETCONF_USER (enable ssh and netconf on device)
84
   NETCONF_PASS
85
   If beanstalk is selected the following should be left intact.
86
   BROKER_HOST (beanstalk host)
87
   BROKER_PORT (beanstalk port)
88
   SERVER_EMAIL
89
   EMAIL_SUBJECT_PREFIX
90
   If beanstalk is selected the following should be left intact.
91
   BROKER_URL (beanstalk url)
92
   SHIB_AUTH_ENTITLEMENT (if you go for Shibboleth authentication)
93
   NOTIFY_ADMIN_MAILS (bcc mail addresses)
94
   PROTECTED_SUBNETS (subnets for which source or destination address will prevent rule creation and notify the NOTIFY_ADMIN_MAILS)
95
   The whois client is meant to be used in case you have inserted peers with their ASes in the peers table and wish to get network info for each one in an automated manner.
96
   PRIMARY_WHOIS
97
   ALTERNATE_WHOIS
98
   If you wish to deploy FoD with Shibboleth change the following attributes according to your setup:
99
   SHIB_AUTH_ENTITLEMENT = 'urn:mace'
100
   SHIB_ADMIN_DOMAIN = 'example.com'
101
   SHIB_LOGOUT_URL = 'https://example.com/Shibboleth.sso/Logout'
102
   SHIB_USERNAME = ['HTTP_EPPN']
103
   SHIB_MAIL = ['mail', 'HTTP_MAIL', 'HTTP_SHIB_INETORGPERSON_MAIL']
104
   SHIB_FIRSTNAME = ['HTTP_SHIB_INETORGPERSON_GIVENNAME']
105
   SHIB_LASTNAME = ['HTTP_SHIB_PERSON_SURNAME']
106
   SHIB_ENTITLEMENT = ['HTTP_SHIB_EP_ENTITLEMENT']
107

  
108
If you have not installed an outgoing mail server you can always use
109
your own account (either corporate or gmail, hotmail ,etc) by adding
110
the following lines in settings.py:
111

  
112
   EMAIL_USE_TLS = True #(or False)
113
   EMAIL_HOST = 'smtp.example.com'
114
   EMAIL_HOST_USER = 'username'
115
   EMAIL_HOST_PASSWORD = 'yourpassword'
116
   EMAIL_PORT = 587 #(outgoing)
117

  
118
Note: Soon we will release a version with django-registration as a means
119
  to add users and Shibboleth as an alternative
120

  
121
Let's move on with some copies and dir creations:
122

  
123
   cp urls.py.dist urls.py
124
   mkdir log
125
   chown -R root:www-data log/
126
   chmod -R g+w log
127

  
128

  
129
System configuration
130
====================
131

  
132
Apache operates as a gunicorn Proxy with WSGI and Shibboleth modules
133
enabled. Depending on the setup the apache configuration may vary:
134

  
135
   a2enmod rewrite
136
   a2enmod proxy
137
   a2enmod ssl
138
   a2enmod proxy_http
139

  
140
If shibboleth is to be used:
141

  
142
   apt-get install libapache2-mod-shib2
143
   a2enmod shib2
144

  
145
Now it is time to configure beanstalk, gunicorn, celery and apache.
146

  
147

  
148
beanstalkd
149
----------
150

  
151
Enable beanstalk by editting /etc/default/beanstalkd:
152

  
153
   vim /etc/default/beanstalkd
154

  
155
Uncomment the line **START=yes** to enable beanstalk
156

  
157
Start beanstalkd:
158

  
159
   service beanstalkd start
160

  
161

  
162
gunicorn.d
163
----------
164

  
165
create and edit /etc/gunicorn.d/fod:
166

  
167
   vim /etc/gunicorn.d/fod
168

  
169
FoD is served via gunicorn and is then proxied by Apache. If the above
170
directory conventions have been followed so far, then your
171
configuration should be:
172

  
173
   CONFIG = {
174
       'mode': 'django',
175
       'working_dir': '/srv/flowspy',
176
       'args': (
177
           '--bind=127.0.0.1:8081',
178
           '--workers=1',
179
           '--timeout=360',
180
           '--worker-class=egg:gunicorn#gevent',
181
           '--log-level=debug',
182
           'settings.py',
183
       ),
184
   }
185

  
186

  
187
celery.d
188
--------
189

  
190
Celery is used over beanstalkd to apply firewall rules in a serial
191
manner so that locks are avoided on the flowspec capable device. In
192
our setup celery runs via django. That is why the python-django-celery
193
package was installed.
194

  
195
Create the celeryd daemon at /etc/init.d/celeryd:
196

  
197
   vim /etc/init.d/celeryd
198

  
199
The configuration should be:
200

  
201
   #!/bin/sh -e
202
   # ============================================
203
   #  celeryd - Starts the Celery worker daemon.
204
   # ============================================
205
   #
206
   # :Usage: /etc/init.d/celeryd {start|stop|force-reload|restart|try-restart|status}
207
   # :Configuration file: /etc/default/celeryd
208
   #
209
   # See http://docs.celeryq.org/en/latest/cookbook/daemonizing.html#init-script-celeryd
210

  
211

  
212
   ### BEGIN INIT INFO
213
   # Provides:          celeryd
214
   # Required-Start:    $network $local_fs $remote_fs
215
   # Required-Stop:     $network $local_fs $remote_fs
216
   # Default-Start:     2 3 4 5
217
   # Default-Stop:      0 1 6
218
   # Short-Description: celery task worker daemon
219
   ### END INIT INFO
220

  
221
   #set -e
222

  
223
   DEFAULT_PID_FILE="/var/run/celeryd@%n.pid"
224
   DEFAULT_LOG_FILE="/var/log/celeryd@%n.log"
225
   DEFAULT_LOG_LEVEL="INFO"
226
   DEFAULT_NODES="celery"
227
   DEFAULT_CELERYD="-m celery.bin.celeryd_detach"
228

  
229
   # /etc/init.d/celeryd: start and stop the celery task worker daemon.
230

  
231
   CELERY_DEFAULTS=${CELERY_DEFAULTS:-"/etc/default/celeryd"}
232

  
233
   test -f "$CELERY_DEFAULTS" && . "$CELERY_DEFAULTS"
234
   if [ -f "/etc/default/celeryd" ]; then
235
       . /etc/default/celeryd
236
   fi
237

  
238
   CELERYD_PID_FILE=${CELERYD_PID_FILE:-${CELERYD_PIDFILE:-$DEFAULT_PID_FILE}}
239
   CELERYD_LOG_FILE=${CELERYD_LOG_FILE:-${CELERYD_LOGFILE:-$DEFAULT_LOG_FILE}}
240
   CELERYD_LOG_LEVEL=${CELERYD_LOG_LEVEL:-${CELERYD_LOGLEVEL:-$DEFAULT_LOG_LEVEL}}
241
   CELERYD_MULTI=${CELERYD_MULTI:-"celeryd-multi"}
242
   CELERYD=${CELERYD:-$DEFAULT_CELERYD}
243
   CELERYCTL=${CELERYCTL:="celeryctl"}
244
   CELERYD_NODES=${CELERYD_NODES:-$DEFAULT_NODES}
245

  
246
   export CELERY_LOADER
247

  
248
   if [ -n "$2" ]; then
249
       CELERYD_OPTS="$CELERYD_OPTS $2"
250
   fi
251

  
252
   CELERYD_LOG_DIR=`dirname $CELERYD_LOG_FILE`
253
   CELERYD_PID_DIR=`dirname $CELERYD_PID_FILE`
254
   if [ ! -d "$CELERYD_LOG_DIR" ]; then
255
       mkdir -p $CELERYD_LOG_DIR
256
   fi
257
   if [ ! -d "$CELERYD_PID_DIR" ]; then
258
       mkdir -p $CELERYD_PID_DIR
259
   fi
260

  
261
   # Extra start-stop-daemon options, like user/group.
262
   if [ -n "$CELERYD_USER" ]; then
263
       DAEMON_OPTS="$DAEMON_OPTS --uid=$CELERYD_USER"
264
       chown "$CELERYD_USER" $CELERYD_LOG_DIR $CELERYD_PID_DIR
265
   fi
266
   if [ -n "$CELERYD_GROUP" ]; then
267
       DAEMON_OPTS="$DAEMON_OPTS --gid=$CELERYD_GROUP"
268
       chgrp "$CELERYD_GROUP" $CELERYD_LOG_DIR $CELERYD_PID_DIR
269
   fi
270

  
271
   if [ -n "$CELERYD_CHDIR" ]; then
272
       DAEMON_OPTS="$DAEMON_OPTS --workdir=\"$CELERYD_CHDIR\""
273
   fi
274

  
275

  
276
   check_dev_null() {
277
       if [ ! -c /dev/null ]; then
278
           echo "/dev/null is not a character device!"
279
           exit 1
280
       fi
281
   }
282

  
283

  
284
   export PATH="${PATH:+$PATH:}/usr/sbin:/sbin"
285

  
286

  
287
   stop_workers () {
288
       $CELERYD_MULTI stop $CELERYD_NODES --pidfile="$CELERYD_PID_FILE"
289
   }
290

  
291

  
292
   start_workers () {
293
       $CELERYD_MULTI start $CELERYD_NODES $DAEMON_OPTS        \
294
                            --pidfile="$CELERYD_PID_FILE"      \
295
                            --logfile="$CELERYD_LOG_FILE"      \
296
                            --loglevel="$CELERYD_LOG_LEVEL"    \
297
                            --cmd="$CELERYD"                   \
298
                            $CELERYD_OPTS
299
   }
300

  
301

  
302
   restart_workers () {
303
       $CELERYD_MULTI restart $CELERYD_NODES $DAEMON_OPTS      \
304
                              --pidfile="$CELERYD_PID_FILE"    \
305
                              --logfile="$CELERYD_LOG_FILE"    \
306
                              --loglevel="$CELERYD_LOG_LEVEL"  \
307
                              --cmd="$CELERYD"                 \
308
                              $CELERYD_OPTS
309
   }
310

  
311

  
312

  
313
   case "$1" in
314
       start)
315
           check_dev_null
316
           start_workers
317
       ;;
318

  
319
       stop)
320
           check_dev_null
321
           stop_workers
322
       ;;
323

  
324
       reload|force-reload)
325
           echo "Use restart"
326
       ;;
327

  
328
       status)
329
           $CELERYCTL status $CELERYCTL_OPTS
330
       ;;
331

  
332
       restart)
333
           check_dev_null
334
           restart_workers
335
       ;;
336

  
337
       try-restart)
338
           check_dev_null
339
           restart_workers
340
       ;;
341

  
342
       *)
343
           echo "Usage: /etc/init.d/celeryd {start|stop|restart|try-restart|kill}"
344
           exit 1
345
       ;;
346
   esac
347

  
348
   exit 0
349

  
350
and make it executable:
351

  
352
   chmod +x /etc/init.d/celeryd
353

  
354
celeryd requires a /etc/default/celeryd file to be in place. Thus we
355
are going to create this file (/etc/default/celeryd):
356

  
357
   vim /etc/default/celeryd
358

  
359
Again if the directory conventions have been followed the file is (pay
360
attention to the CELERYD_USER, CELERYD_GROUP and change accordingly)
361

  
362
   # Name of nodes to start, here we have a single node
363
   CELERYD_NODES="w1"
364
   # or we could have three nodes:
365
   #CELERYD_NODES="w1 w2 w3"
366

  
367
   # Where to chdir at start.
368
   CELERYD_CHDIR="/srv/flowspy"
369
   # How to call "manage.py celeryd_multi"
370
   CELERYD_MULTI="$CELERYD_CHDIR/manage.py celeryd_multi"
371

  
372
   # How to call "manage.py celeryctl"
373
   CELERYCTL="$CELERYD_CHDIR/manage.py celeryctl"
374

  
375
   # Extra arguments to celeryd
376
   #CELERYD_OPTS="--time-limit=300 --concurrency=8"
377
   CELERYD_OPTS="-E -B"
378
   # Name of the celery config module.
379
   CELERY_CONFIG_MODULE="celeryconfig"
380

  
381
   # %n will be replaced with the nodename.
382
   CELERYD_LOG_FILE="$CELERYD_CHDIR/celery_var/log/celery/%n.log"
383
   CELERYD_PID_FILE="$CELERYD_CHDIR/celery_var/run/celery/%n.pid"
384

  
385
   # Workers should run as an unprivileged user.
386
   CELERYD_USER="user"
387
   CELERYD_GROUP="user"
388

  
389
   # Name of the projects settings module.
390
   export DJANGO_SETTINGS_MODULE="settings"
391

  
392

  
393
Apache
394
------
395

  
396
Apache proxies gunicorn. Things are more flexible here as you may
397
follow your own configuration and conventions. Create and edit
398
/etc/apache2/sites-available/fod. You should set <server_name> and
399
<admin_mail> along with your certificates. If under testing
400
environment, you can use the provided snakeoil certs. If you do not
401
intent to use Shibboleth delete or comment the corresponding
402
configuration parts inside **Shibboleth configuration**
403

  
404
   vim /etc/apache2/sites-available/fod
405

  
406
Again if the directory conventions have been followed the file should
407
be:
408

  
409
   <VirtualHost *:80>
410
           ServerAdmin webmaster@localhost
411
           ServerName      <server_name>
412
           DocumentRoot /var/www
413
           <Directory />
414
                   Options FollowSymLinks
415
                   AllowOverride None
416
           </Directory>
417
           <Directory /var/www/>
418
                   Options Indexes FollowSymLinks MultiViews
419
                   AllowOverride None
420
                   Order allow,deny
421
                   allow from all
422
           </Directory>
423

  
424
           ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
425
           <Directory "/usr/lib/cgi-bin">
426
                   AllowOverride None
427
                   Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
428
                   Order allow,deny
429
                   Allow from all
430
           </Directory>
431

  
432
           ErrorLog ${APACHE_LOG_DIR}/error.log
433

  
434
           # Possible values include: debug, info, notice, warn, error, crit,
435
           # alert, emerg.
436
           LogLevel warn
437

  
438
           CustomLog ${APACHE_LOG_DIR}/access.log combined
439

  
440
       Alias /doc/ "/usr/share/doc/"
441
       <Directory "/usr/share/doc/">
442
           Options Indexes MultiViews FollowSymLinks
443
           AllowOverride None
444
           Order deny,allow
445
           Deny from all
446
           Allow from 127.0.0.0/255.0.0.0 ::1/128
447
       </Directory>
448

  
449
           RewriteEngine On
450
           RewriteCond %{HTTPS} off
451
           RewriteRule ^/(.*) https://<server_name>/$1 [L,R]
452

  
453
   </VirtualHost>
454
   <VirtualHost *:443>
455
           ServerName       <server_name>
456
           ServerAdmin             <admin_mail>
457
           ServerSignature         On
458

  
459
           SSLEngine on
460
           SSLCertificateFile      /etc/ssl/certs/example.com.crt
461
           SSLCertificateChainFile /etc/ssl/certs/example.com.crt
462
           SSLCertificateKeyFile   /etc/ssl/private/example.com.key
463

  
464
           AddDefaultCharset       UTF-8
465
           IndexOptions            +Charset=UTF-8
466

  
467
           # Shibboleth configuration
468
           ShibConfig              /etc/shibboleth/shibboleth2.xml
469
           Alias                   /shibboleth-sp  /usr/share/shibboleth
470

  
471
           <Location /fod/login>
472
           AuthType shibboleth
473
           ShibRequireSession On
474
           ShibUseHeaders On
475
           require valid-user
476
       </Location>
477

  
478
           # Shibboleth debugging CGI script
479
           ScriptAlias /shibboleth/test /usr/lib/cgi-bin/shibtest.cgi
480
           <Location /shibboleth/test>
481
                   AuthType shibboleth
482
                   ShibRequireSession On
483
                   ShibUseHeaders On
484
                   require valid-user
485
           </Location>
486

  
487
           <Location /Shibboleth.sso>
488
                   SetHandler shib
489
           </Location>
490

  
491
           # End of Shibboleth configuration
492

  
493
           <Location /admin/media/>
494
                   SetHandler      None
495
           </Location>
496

  
497
           Alias /admin/media      /usr/share/pyshared/django/contrib/admin/media
498
           Alias /media  /usr/share/pyshared/django/contrib/admin/media
499
                   DocumentRoot /var/www
500
           <Directory /var/www/>
501
                   Options Indexes FollowSymLinks MultiViews
502
                   AllowOverride None
503
                   Order allow,deny
504
                   allow from all
505
           </Directory>
506

  
507

  
508

  
509
           <Proxy *>
510
           Order allow,deny
511
           Allow from all
512
           </Proxy>
513

  
514
           SSLProxyEngine        off
515
           ProxyErrorOverride    off
516
       ProxyTimeout    28800
517
           ProxyPass        /fod http://localhost:8081/fod retry=0
518
           ProxyPassReverse /fod http://localhost:8081/fod
519

  
520
           LogLevel warn
521
           ErrorLog /var/log/apache2/ssl-error.log
522
           CustomLog /var/log/apache2/ssl-access.log combined
523

  
524

  
525

  
526

  
527
           Alias /fodstatic        /srv/flowspy/static
528

  
529
   </VirtualHost>
530

  
531
Now, enable your site. You might want to disable the default site if
532
fod is the only site you host on your server:
533

  
534
   a2dissite default
535
   a2ensite fod
536

  
537
You are not far away from deploying FoD. When asked for a super user,
538
create one:
539

  
540
   cd /srv/flowspy
541
   python manage.py syncdb
542
   python manage.py migrate
543

  
544
Restart, gunicorn and apache:
545

  
546
   service gunicorn restart && service apache2 restart
547

  
548

  
549
Testing the platform
550
====================
551

  
552
Log in to the admin interface via https://<your ip>/fod/admin. Go to
553
Peer ranges and add a new range (part of/or a complete subnet), eg.
554
83.212.0.0/19 Go to Peers and add a new peer, eg. id: 1, name: Test,
555
AS: 16503, tag: TEST and move the network you have crteated from
556
Avalable to Chosen. From the admin front, go to User, and edit your
557
user. From the bottom of the page, select the TEST peer and save. Last
558
but not least, modify as required the existing (example.com) Site
559
instance (admin home->Sites). You are done. As you are logged-in via
560
the admin, there is no need for Shibboleth. Go to https://<your
561
ip>/fod/ and create a new rule. Your rule should be applied on the
562
flowspec capable device after aprox. 10 seconds.
563

  
564

  
565
Branding
566
========
567

  
568
Via the admin interface you can modify flatpages to suit your needs
569

  
570

  
571
Logos
572
-----
573

  
574
Inside the static folder you will find two empty png files:
575
fod_logo.xcf (Gimp file) and shib_login.dist.png. Edit those two with
576
your favourite image processing software and save them as fod_logo.png
577
(under static/img/) and shib_login.png (under static/). Image sizes
578
are optimized to operate without any other code changes. In case you
579
want to incorporate images of different sizes you have to fine tune
580
css and/or html as well.
581

  
582

  
583
Footer
584
------
585

  
586
Under the templates folder (templates), you can alter the footer.html
587
file to include your own footer messages, badges, etc.
588

  
589

  
590
Welcome Page
591
------------
592

  
593
Under the templates folder (templates), you can alter the welcome page
594
- welcome.html with your own images, carousel, videos, etc.
b/locale/el/LC_MESSAGES/django.po
8 8
msgstr ""
9 9
"Project-Id-Version: PACKAGE VERSION\n"
10 10
"Report-Msgid-Bugs-To: \n"
11
"POT-Creation-Date: 2014-04-01 15:49+0300\n"
11
"POT-Creation-Date: 2014-04-07 12:30+0300\n"
12 12
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13 13
"Last-Translator: Leonidas Poulopoulos <leopoul@grnet.gr>\n"
14 14
"Language-Team: LANGUAGE <LL@li.org>\n"
......
129 129
msgid "Port should be an integer"
130 130
msgstr "Η port θα πρέπει να είναι ένας ακέραιος αριθμός"
131 131

  
132
#: flowspec/models.py:128 templates/apply.html:237
132
#: flowspec/models.py:128 templates/apply.html:242
133 133
#: templates/user_routes.html:38 templates/overview/index.html:355
134 134
#: templates/overview/index.html.py:383
135 135
msgid "Name"
......
139 139
msgid "Network address. Use address/CIDR notation"
140 140
msgstr "Διεύθυνση δικτύου/υποδικτύου. Χρησιμοποιήστε σύνταξη διεύθυνσης/CIDR"
141 141

  
142
#: flowspec/models.py:130 templates/apply.html:263
142
#: flowspec/models.py:130 templates/apply.html:268
143 143
msgid "Source Address"
144 144
msgstr "Διεύθυνση Πηγής"
145 145

  
......
147 147
msgid "Source Port"
148 148
msgstr "Port Πηγής"
149 149

  
150
#: flowspec/models.py:132 templates/apply.html:275
150
#: flowspec/models.py:132 templates/apply.html:280
151 151
msgid "Destination Address"
152 152
msgstr "Διεύθυνση Προορισμού"
153 153

  
......
174 174
msgid "Status"
175 175
msgstr "Κατάσταση"
176 176

  
177
#: flowspec/models.py:148 templates/apply.html:362 templates/dashboard.html:69
177
#: flowspec/models.py:148 templates/apply.html:367 templates/dashboard.html:69
178 178
#: templates/user_routes.html:43 templates/overview/index.html:388
179 179
msgid "Expires"
180 180
msgstr "Λήγει"
......
184 184
msgid "Response"
185 185
msgstr "Απόκριση Δικτύου"
186 186

  
187
#: flowspec/models.py:150 templates/apply.html:376
187
#: flowspec/models.py:150 templates/apply.html:381
188 188
msgid "Comments"
189 189
msgstr "Σχόλια"
190 190

  
......
196 196
msgid "Invalid network address format at Source Field"
197 197
msgstr "Λανθασμένη μορφή διεύθυνσης δικυου στο πεδίο Πηγή"
198 198

  
199
#: flowspec/views.py:179
199
#: flowspec/views.py:181
200 200
msgid ""
201 201
"Insufficient rights on administrative networks. Cannot add rule. Contact "
202 202
"your administrator"
......
204 204
"Μη επαρκή δικαιώματα στα διαχειριστικά δίκτυα. Η προσθήκη φίλτρων δεν είναι "
205 205
"εφικτή. Επικοινωνήστε με το διαχειριστή σας"
206 206

  
207
#: flowspec/views.py:240
207
#: flowspec/views.py:242
208 208
#, python-format
209 209
msgid "Insufficient rights to edit rule %s"
210 210
msgstr "Μη επαρκή δικαιώματα για την επεξεργασία του φίλτρου %s"
211 211

  
212
#: flowspec/views.py:252
212
#: flowspec/views.py:254
213 213
#, python-format
214 214
msgid "Cannot edit a pending rule: %s."
215 215
msgstr "Δεν είναι δυνατή η επεξεργασία ενός φίλτρου (%s) σε κατάσταση pending "
216 216

  
217
#: flowspec/views.py:395
217
#: flowspec/views.py:397
218 218
msgid ""
219 219
"Your idP should release the HTTP_EPPN attribute towards this service<br>"
220 220
msgstr ""
221 221
"Ο idP σας θα πρέπει να παρέχει την HTTP_EPPN παράμετερο στην υπηρεσία<br>"
222 222

  
223
#: flowspec/views.py:399
223
#: flowspec/views.py:401
224 224
msgid ""
225 225
"Your idP should release an appropriate HTTP_SHIB_EP_ENTITLEMENT attribute "
226 226
"towards this service<br>"
......
228 228
"Ο idP σας θα πρέπει να παρέχει την HTTP_SHIB_EP_ENTITLEMENT παράμετερο στην "
229 229
"υπηρεσία<br>"
230 230

  
231
#: flowspec/views.py:401
231
#: flowspec/views.py:403
232 232
msgid ""
233 233
"Your idP should release the HTTP_SHIB_INETORGPERSON_MAIL attribute towards "
234 234
"this service"
......
236 236
"Ο idP σας θα πρέπει να παρέχει την HTTP_SHIB_INETORGPERSON_MAIL παράμετερο "
237 237
"στην υπηρεσία<br>"
238 238

  
239
#: flowspec/views.py:432 flowspec/views.py:540
239
#: flowspec/views.py:434 flowspec/views.py:542
240 240
#, python-format
241 241
msgid ""
242 242
"User account <strong>%s</strong> is pending activation. Administrators have "
......
250 250
"ενεργοποιηθεί για μεγάλο χρονικό διάστημα, επικοινωνήστε με τον τεχνικό σας "
251 251
"υπέυθυνο ή το Helpdesk του ΕΔΕΤ."
252 252

  
253
#: flowspec/views.py:436
253
#: flowspec/views.py:438
254 254
msgid ""
255 255
"Something went wrong during user authentication. Contact your administrator"
256 256
msgstr ""
257 257
"Παρουσιάστηκε ένα σφάλμα κατά την είσοδο του χρήστη. Επικοινωνήστε με το "
258 258
"διαχειριστή σας"
259 259

  
260
#: flowspec/views.py:440
260
#: flowspec/views.py:442
261 261
#, python-format
262 262
msgid "Invalid login procedure. Error: %s"
263 263
msgstr "Εσφαλμένη διαδικασία εισόδου. Σφάλμα: %s"
264 264

  
265
#: flowspec/views.py:530
265
#: flowspec/views.py:532
266 266
msgid ""
267 267
"Violation warning: User account is already associated with an institution."
268 268
"The event has been logged and our administrators will be notified about it"
......
299 299
msgid "Create new Rule"
300 300
msgstr "Δημιουργία νέου Φίλτρου"
301 301

  
302
#: templates/apply.html:16 templates/apply.html.py:210
302
#: templates/apply.html:16 templates/apply.html.py:215
303 303
msgid "Edit rule"
304 304
msgstr "Επεξεργασία φίλτρου"
305 305

  
......
307 307
msgid "Create rule"
308 308
msgstr "Δημιουργία φίλτρου"
309 309

  
310
#: templates/apply.html:211
310
#: templates/apply.html:216
311 311
msgid "Apply for a new rule"
312 312
msgstr "Αίτηση δημιουργίας νέου φίλτρου"
313 313

  
314
#: templates/apply.html:249 templates/user_routes.html:42
314
#: templates/apply.html:254 templates/user_routes.html:42
315 315
#: templates/overview/index.html:387
316 316
msgid "Applier"
317 317
msgstr "Χρήστης"
318 318

  
319
#: templates/apply.html:287
319
#: templates/apply.html:292
320 320
msgid "Protocol(s)"
321 321
msgstr "Πρωτόκολλο"
322 322

  
323
#: templates/apply.html:296
323
#: templates/apply.html:301
324 324
msgid "Fragment Type"
325 325
msgstr ""
326 326

  
327
#: templates/apply.html:308
327
#: templates/apply.html:313
328 328
msgid ""
329 329
"Select source/destination port(s), or select common port(s) for both source/"
330 330
"destination"
331 331
msgstr ""
332 332

  
333
#: templates/apply.html:311
333
#: templates/apply.html:316
334 334
msgid "Src. Port(s)"
335 335
msgstr "Port Πηγής"
336 336

  
337
#: templates/apply.html:317
337
#: templates/apply.html:322
338 338
msgid "Dest. Port(s)"
339 339
msgstr "Port Προορισμού"
340 340

  
341
#: templates/apply.html:323
341
#: templates/apply.html:328
342 342
#, fuzzy
343 343
msgid "Port(s)"
344 344
msgstr "Port Πηγής"
345 345

  
346
#: templates/apply.html:333
346
#: templates/apply.html:338
347 347
msgid "Add Port"
348 348
msgstr "Νέα port"
349 349

  
350
#: templates/apply.html:337
350
#: templates/apply.html:342
351 351
msgid "Add New Port"
352 352
msgstr "Νέα port"
353 353

  
354
#: templates/apply.html:339 templates/apply.html.py:398
354
#: templates/apply.html:344 templates/apply.html.py:403
355 355
msgid "Add new port"
356 356
msgstr "Νέα port"
357 357

  
358
#: templates/apply.html:350
358
#: templates/apply.html:355
359 359
msgid "Then Actions"
360 360
msgstr "Ενέργειες Φίλτρου"
361 361

  
362
#: templates/apply.html:389 templates/registration/activate_edit.html:58
362
#: templates/apply.html:394 templates/registration/activate_edit.html:58
363 363
#: templates/registration/select_institution.html:53
364 364
msgid "Apply"
365 365
msgstr "Εφαρμογή"
......
389 389
msgstr "Έξοδος"
390 390

  
391 391
#: templates/base.html:148 templates/base.html.py:154
392
#: templates/welcome.html:47 templates/b3theme/base.html:103
392
#: templates/welcome.html:73 templates/b3theme/base.html:103
393 393
msgid "Shibboleth Login"
394 394
msgstr "Είσοδος με Shibboleth"
395 395

  
......
517 517
msgid "Info"
518 518
msgstr "Πληροφορίες"
519 519

  
520
#: templates/footer.html:11 templates/welcome.html:38
520
#: templates/footer.html:11 templates/welcome.html:64
521 521
msgid "Service Terms"
522 522
msgstr "Όροι Χρήσης"
523 523

  
......
540 540
msgstr ""
541 541

  
542 542
#: templates/profile.html:64 templates/overview/index.html:353
543
#, fuzzy
543
#: templates/overview/login.html:53
544 544
msgid "Username"
545
msgstr "????????"
545
msgstr "?????? ??????"
546 546

  
547 547
#: templates/profile.html:65
548 548
msgid "First name"
......
588 588
msgid "Resync"
589 589
msgstr ""
590 590

  
591
#: templates/welcome.html:3
591
#: templates/welcome.html:3 templates/overview/login.html:71
592 592
msgid "Login"
593 593
msgstr "Είσοδος"
594 594

  
595
#: templates/welcome.html:27
596
msgid "Welcome to GRNET's FoD service."
597
msgstr "Καλωσήρθατε στην υπηρεσία FoD του ΕΔΕΤ."
595
#: templates/welcome.html:35
596
msgid "Join Now"
597
msgstr ""
598 598

  
599
#: templates/welcome.html:36
599
#: templates/welcome.html:62
600 600
msgid "What"
601 601
msgstr "Τι"
602 602

  
603
#: templates/welcome.html:37
603
#: templates/welcome.html:63
604 604
msgid "If you are new to the service, take some time to read the"
605 605
msgstr "Εάν χρησιμοποιείτε την υπηρεσία για πρώτη φορά, δείτε την"
606 606

  
607
#: templates/welcome.html:37
607
#: templates/welcome.html:63
608 608
msgid "Service Description"
609 609
msgstr "Περιγραφή της Υπηρεσίας"
610 610

  
611
#: templates/welcome.html:38
611
#: templates/welcome.html:64
612 612
msgid "Before asking why? take some time to look at the"
613 613
msgstr "Πριν ρωτήσετε γιατί; διαβάστε την ενότητα"
614 614

  
615
#: templates/welcome.html:42
615
#: templates/welcome.html:68
616 616
msgid "How"
617 617
msgstr "Πως"
618 618

  
619
#: templates/welcome.html:43
619
#: templates/welcome.html:69
620 620
msgid "If you have properly set your Shibboleth attributes, you may proceed"
621 621
msgstr ""
622 622
"Έαν έχετε ορίσει ορθά τις απαιτούμενες παραμέτρους του Shibboleth, μπορείτε "
623 623
"να συνεχίσετε"
624 624

  
625
#: templates/welcome.html:52
625
#: templates/welcome.html:78
626 626
msgid "Help"
627 627
msgstr "Βοήθεια"
628 628

  
629
#: templates/welcome.html:54
629
#: templates/welcome.html:79
630 630
msgid ""
631 631
"For troubleshooting info and remarks do not hesitate to contact GRNET's "
632 632
"Helpdesk."
......
665 665
msgid "Key Expired"
666 666
msgstr "Λήξη Φίλτρου"
667 667

  
668
#: templates/overview/login.html:3 templates/overview/login.html.py:14
668
#: templates/overview/login.html:19 templates/overview/login.html.py:28
669 669
msgid "Overview Login"
670 670
msgstr "Εισόδος στην Επισκόπηση"
671 671

  
672
#: templates/overview/login.html:61
673
msgid "Password"
674
msgstr ""
675

  
672 676
#: templates/registration/activate.html:4
673 677
#: templates/registration/activate.html:21
674 678
msgid "Activation Status"
......
709 713
#: templates/registration/activation_complete.html:34
710 714
msgid "The user will be notified about his/her account activation"
711 715
msgstr "Ο χρήστης θα ενημερωθεί για την ενεργοποίηση του λογαριασμού"
716

  
717
#~ msgid "Welcome to GRNET's FoD service."
718
#~ msgstr "Καλωσήρθατε στην υπηρεσία FoD του ΕΔΕΤ."
b/templates/apply.html
24 24
    <link href="{{STATIC_URL}}b3theme/css/plugins/timeline/timeline.css" rel="stylesheet">
25 25
    <link href="{{STATIC_URL}}datepicker/css/datepicker.css" rel="stylesheet">
26 26
{% endblock %}
27

  
28
{% block extraheadbottom %}
29
<style type="text/css">
30

  
31

  
32

  
33
#rule_form_container input:not([type="submit"]), #rule_form_container select {
34
    background: none repeat scroll 0 0 #FFFFFF;
35
    border: 1px solid #DDDDDD;
36
	-moz-border-radius: 3px; border-radius:3px; -webkit-border-radius: 3px; 
37
    float: left;
38
    font-family: "Century Gothic",Helvetica,sans-serif;
39
    font-size: 13px;
40
    outline: medium none;
41
    padding: 5px;
42
    width: 180px;
43
}
44

  
45

  
46
#rule_form_container{
47
	-moz-border-radius: 10px 10px 10px 10px; border-radius:10px; -webkit-border-radius: 10px;
48
	-moz-box-shadow: 0 0 3px #AAAAAA; box-shadow: 0 0 3px #AAAAAA; -webkit-box-shadow: 0 0 3px #AAAAAA; 
49
	background-color: #F9F9F9;
50
	border: 2px solid #FFFFFF;
51
	overflow: hidden;
52
    width: 800px;
53
	}
54
#rule_form_container div label {
55
    color: #666666;
56
    float: left;
57
    font-family: "Century Gothic",Helvetica,sans-serif;
58
    font-size: 15px;
59
    font-weight: bold;
60
    line-height: 26px;
61
    margin-right: 15px;
62
    text-align: right;
63
    text-shadow: 1px 1px 1px #FFFFFF;
64
    width: 180px;
65
}
66
#rule_form_container p.submit {
67
    background: none repeat scroll 0 0 transparent;
68
    border: medium none;
69
    box-shadow: none;
70
}
71

  
72
.errorlist{
73
	list-style: none outside none;
74
}
75

  
76
</style>
77
{% endblock %}
78

  
27 79
{% block pagejsbottom %}
28 80
<script type="text/javascript" src="{{STATIC_URL}}datepicker/js/bootstrap-datepicker.js"></script>
29 81
<script>
......
154 206
</script>
155 207
{% endblock %}
156 208
{% block contentplaceholder %}
157
<style type="text/css">
158

  
159 209

  
160

  
161
#rule_form_container input:not([type="submit"]), #rule_form_container select {
162
    background: none repeat scroll 0 0 #FFFFFF;
163
    border: 1px solid #DDDDDD;
164
	-moz-border-radius: 3px; border-radius:3px; -webkit-border-radius: 3px; 
165
    float: left;
166
    font-family: "Century Gothic",Helvetica,sans-serif;
167
    font-size: 13px;
168
    outline: medium none;
169
    padding: 5px;
170
    width: 180px;
171
}
172

  
173

  
174
#rule_form_container{
175
	-moz-border-radius: 10px 10px 10px 10px; border-radius:10px; -webkit-border-radius: 10px;
176
	-moz-box-shadow: 0 0 3px #AAAAAA; box-shadow: 0 0 3px #AAAAAA; -webkit-box-shadow: 0 0 3px #AAAAAA; 
177
	background-color: #F9F9F9;
178
	border: 2px solid #FFFFFF;
179
	overflow: hidden;
180
    width: 800px;
181
	}
182
#rule_form_container div label {
183
    color: #666666;
184
    float: left;
185
    font-family: "Century Gothic",Helvetica,sans-serif;
186
    font-size: 15px;
187
    font-weight: bold;
188
    line-height: 26px;
189
    margin-right: 15px;
190
    text-align: right;
191
    text-shadow: 1px 1px 1px #FFFFFF;
192
    width: 180px;
193
}
194
#rule_form_container p.submit {
195
    background: none repeat scroll 0 0 transparent;
196
    border: medium none;
197
    box-shadow: none;
198
}
199

  
200
.errorlist{
201
	list-style: none outside none;
202
}
203

  
204
</style>
205 210
            <div class="row">
206 211
                <div class="col-lg-12">
207 212
                    <h1 class="page-header"> {% if edit %}{% trans "Edit rule" %}: {{form.data.name}}
b/templates/overview/login.html
1
{% extends "base.html" %} 
1
{% extends "b3theme/base.html" %}
2
{% load widget_tweaks %}
2 3
{% load i18n %}
3
{% block title %}{% trans "Overview Login" %}{% endblock %}
4
   {% block extraheadbottom %}
5
<style>
6
	@media (min-width: 768px) {
7
		#page-wrapper {
8
		    border-left: none;
9
		    margin: 0;
10
		}
11
}
12
.errorlist{
13
	list-style: none outside none;
14
}
15
</style>
16
{% endblock %}
17
{% block title %}
18
	
19
		{% trans "Overview Login" %}
4 20

  
5
    {% block content %}
6
    <div class="container-fluid">
7
      <div class="row-fluid">
8
        <div class="span2">
9
        </div><!--/span-->
21
{% endblock %}
10 22

  
11
        <div class="span10">
12
            <div class="row-fluid">
13
                <!--/span-->
14
                <h3 class="muted">{% trans "Overview Login" %}</h3>
15
                <hr>
16
                    
17
                    <form class="form-horizontal" method="post"
18
                            action="{% url altlogin %}">
19
    
20
                            {% if form.non_field_errors %} {% for err in form.non_field_errors %}
21
                            <div class="control-group error ">
22
                                <div class="controls error">
23
                                    <span style="color: #B94A48;">{{err}}</span>
24
                                </div>
25
                            </div>
26
                            {% endfor %} {% endif %} {% csrf_token %}
27
                            <div class="control-group {% if form.username.errors %} error {% endif %}">
28
                                <label class="control-label" for="id_username">Username</label>
29
                                <div class="controls">
30
                                    {{ form.username }} {% if form.username.errors %} <span class="help-inline"> {{ form.username.errors|join:", "}} </span> {% endif %}
31
                                </div>
32
                            </div>
33
                            <div class="control-group {% if form.password.errors %} error {% endif %}">
34
                                <label class="control-label" for="id_password">Password</label>
35
                                <div class="controls">
36
                                    {{ form.password }} {% if form.password.errors %} <span
37
                                        class="help-inline"> {{ form.password.errors|join:", "}} </span> {% endif %}
38
                                </div>
39
                            </div>
40
                            <div class="control-group">
41
                                <div class="controls">
42
                                    <button type="submit" class="btn">Sign in</button>
43
                                    <input type="hidden" name="next" value="{% url overview %}" />
44
                                </div>
45
                            </div>
46
                        </form>
47
                <!--/span-->
48
            </div><!--/row-->
49
        </div><!--/span-->
50 23

  
51
        </div><!--/span-->
52
    </div><!--/.fluid-container-->
24
    {% block contentplaceholder %}
25
    <div class="container">
26
    <div class="row">
27
                <div class="col-lg-12">
28
                    <h1 class="page-header">{% trans "Overview Login" %}</h1>
29
                </div>
30
                <!-- /.col-lg-12 -->
31
            </div>
32
            
33
            
34
<div class="row">
35
                <div class="col-lg-8">
36
                	<div class="panel panel-primary">
37
                        <div class="panel-heading">
38
                            <i class="fa fa-user fa-fw"></i> Login
39
                        </div>
40
                        <!-- /.panel-heading -->
41
                        <div class="panel-body">
42
    <form class="form-horizontal" method="post" action="{% url altlogin %}" role="form">     
43
        
44
            {% csrf_token %}
45
            {% load unescape %}
46
            {% if form.non_field_errors %}
47
            <div class="form-group {% if form.non_field_errors %} has-error {% endif %}" style="color: #A94442;">
48
            	{{ form.non_field_errors|unescape}}
49
            	</div>
50
            {% endif %}
51
               
52
                 <div class="form-group {% if form.username.errors %} has-error {% endif %}">
53
        <label for="id_username" class="col-md-2 control-label"><b>{% trans "Username" %}</b></label>
54
        <div class="col-md-8">
55
            {% render_field form.username class+="form-control"  %}
56
            {% if form.username.errors %} <span class="help-block"> {{ form.username.errors|join:", " }} </span>
57
            {% endif %}
58
        </div>
59
        </div>
60
        <div class="form-group {% if form.password.errors %} has-error {% endif %}">
61
        <label for="id_password" class="col-md-2 control-label"><b>{% trans "Password" %}</b></label>
62
        <div class="col-md-8">
63
            {% render_field form.password class+="form-control" %}
64
            {% if form.password.errors %} <span class="help-block"> {{ form.password.errors|join:", " }} </span>
65
            {% endif %}
66
        </div>
67
        </div>
68
        			 <div class="form-group">
69
			 	<div class="col-md-2"></div>
70
			 	 <div class="col-md-8">
71
			<button type="submit" id="applybutton" value="{% trans 'Login' %}" class="btn btn-md btn-primary">Login</button>
72
				</div>
73
			</div>
74
        
75
            </form>
76
            </div>
77
            </div>  
78
            </div>  
79
            </div>          
80
           </div>
53 81
    {% endblock %}
54 82

  

Also available in: Unified diff