view README @ 245:8423373fbadd

Fixed update script from v1.4.0 to v2.0.0: Keep unused invite codes
author jbe
date Thu May 10 22:44:13 2012 +0200 (2012-05-10)
parents fa394b8a0157
children 5ee7eed2f5b0
line source
2 Setup the database:
3 $ createdb liquid_feedback
4 $ psql -v ON_ERROR_STOP=1 -f core.sql liquid_feedback
6 Optionally insert demo data:
7 $ psql -v ON_ERROR_STOP=1 -f demo.sql liquid_feedback
9 Compile lf_update binary:
10 $ make
12 Ensure that "lf_update dbname=liquid_feedback" is called regularly!
14 It is required that lf_update is executed regulary (i.e. every
15 5 minutes via cron) to update cached supporter counts, to change
16 the state of issues when neccessary, and to calculate the result
17 of votings. If you wish, copy the created lf_update file to
18 /usr/local/bin or a similar directory.
20 On successful run, lf_update will not produce any output
21 and exit with code 0.
23 NOTE: When writing to the database, some INSERTs must be executed
24 within the same transaction, e.g. issues can't exist without
25 an initiative and vice versa.
27 To create an export file, which is containing all but private data,
28 you may use the lf_export shell-script:
29 $ lf_export liquid_feedback export.sql.gz
31 To uninstall the software, delete the lf_update binary
32 and drop the database by entering the following command:
33 $ dropdb liquid_feedback
35 Updating is done using the update scripts in the update/ directory.
36 After updating it is recommended to recreate the schema as follows:
37 $ pg_dump --disable-triggers --data-only DATABASE_NAME > tmp.sql
38 $ dropdb DATABASE_NAME
39 $ createdb DATABASE_NAME
40 $ psql -v ON_ERROR_STOP=1 -f core.sql DATABASE_NAME
41 $ psql -v ON_ERROR_STOP=1 -f tmp.sql DATABASE_NAME
42 $ rm tmp.sql

Impressum / About Us