| 1 | ************************************ |
| 2 | * Install and configure lighttpd * |
| 3 | ************************************ |
| 4 | Install lighttpd: |
| 5 | apt-get install lighttpd |
| 6 | |
| 7 | In '/etc/lighttpd/lighttpd.conf' modify the filed 'server.document-root' |
| 8 | to 'www' folder in bloatit. |
| 9 | Example: |
| 10 | server.document-root = "/home/fred/projets/bloatit/www" |
| 11 | |
| 12 | ## MODIFY lighttpd.conf : |
| 13 | Uncomment 'mod_rewrite' in 'server.modules' |
| 14 | |
| 15 | Add line : server.error-handler-404 = "/en/dopagenotfound" |
| 16 | |
| 17 | Create a symbolic link of '.../deployment/files/fastcgi.conf' in '/etc/lighttpd/conf-enabled/': |
| 18 | cd /etc/lighttpd/conf-enabled/ |
| 19 | ln -s /home/fred/bloatit/deployment/files/fastcgi.conf |
| 20 | |
| 21 | Create a symbolic link of '.../deployment/files/rewrite.lighttpd.conf' in '/etc/lighttpd/conf-enabled/': |
| 22 | cd /etc/lighttpd/conf-enabled/ |
| 23 | ln -s /home/fred/bloatit/deployment/files/rewrite.lighttpd.conf |
| 24 | |
| 25 | ********************** |
| 26 | * Restart lighttpd * |
| 27 | ********************** |
| 28 | Restart lighttpd config: |
| 29 | service lighttpd restart |
| 30 | |
| 31 | Verify the loading in logs:hibernate.cfg.xml not found |
| 32 | cat /var/log/lighttpd/error.log |
| 33 | |
| 34 | ********************** |
| 35 | * Install postgresql * |
| 36 | ********************** |
| 37 | # Install the postgresql package |
| 38 | sudo apt-get install postgresql |
| 39 | sudo apt-get install postgresql-client |
| 40 | |
| 41 | # Use the postgres User to create a new DB and a new User |
| 42 | sudo su postgres |
| 43 | psql |
| 44 | #> CREATE USER bloatit; |
| 45 | #> ALTER ROLE bloatit WITH createdb; |
| 46 | #> CREATE DATABASE bloatit OWNER bloatit; |
| 47 | #> ALTER USER bloatit WITH ENCRYPTED PASSWORD 'passe' ; |
| 48 | #>\q |
| 49 | |
| 50 | # change the authentification method |
| 51 | vim /etc/postgresql/8.4/main/pg_hba.conf |
| 52 | # Go to the end of the file. |
| 53 | # change ident to md5 [EXCEPT FOR THE USER "postgres"] |
| 54 | |
| 55 | #leave the postgres session |
| 56 | exit |
| 57 | |
| 58 | # restart the server |
| 59 | sudo service postgresql restartliquibase-launcher.sh |
| 60 | |
| 61 | # Initialize the database |
| 62 | # go to <Project Home>/main/liquibase |
| 63 | # execute liquibase-launcher.sh update |
| 64 | cd main/liquibase |
| 65 | ./liquibase-launcher.sh update |
| 66 | |
| 67 | ************************************ |
| 68 | * Install gettext * |
| 69 | ************************************ |
| 70 | |
| 71 | sudo apt-get install gettext |
| 72 | |
| 73 | ************************************ |
| 74 | * Configure the java server * |
| 75 | ************************************ |
| 76 | -> copy the files/folders from etc/ to ~/.config/bloatit/ |
| 77 | There are value to configure, see the comments in the files. |
| 78 | |
| 79 | -> copy the files/folders from share/ to ~/.local/share/bloatit/ |
| 80 | |
| 81 | ************************************ |
| 82 | * Configure access right * |
| 83 | ************************************ |
| 84 | |
| 85 | The lighttpd process will need to read in ~/.local/share (depending of java |
| 86 | process user). You may need to run the java process with the lighttpd user or |
| 87 | change the right: |
| 88 | |
| 89 | chmod 777 ~/.local |
| 90 | chmod 777 ~/.local/share |
| 91 | |
| 92 | |
| 93 | Create directory /var/local/lucene/indexes and give write right to it. |
| 94 | |
| 95 | |
| 96 | ************************************ |
| 97 | * Install and run * |
| 98 | ************************************ |
| 99 | |
| 100 | mvn clean install -Dmaven.test.skip=true |
| 101 | cd main |
| 102 | mvn exec:java |
| 103 | |
| 104 | |