-
Notifications
You must be signed in to change notification settings - Fork 0
InstallationInstructions
Installation instructions.
Installation instructions for Database Wiki.
Prerequisites:
- subversion installation
- javac/JDK (Java 1.6)
- ant
- postgreSQL (>= 8.4)
- Firefox web browser (v3.6+), other standards-compliant browsers should also work
-
Check out sources:
git clone https://github.com/jamescheney/database-wiki.git -
Build the sources to class files:
cd database-wiki/trunk/database-wiki ant compile -
Create a PostgreSQL user (e.g.
dbwiki) and a database owned by that user (e.g. alsodbwiki). Give the user a password. Make sure the server is running and the password is correct before proceeding. If you want to use a remote database then you may need to ask its administrator to do this for you, if not, consult the PostgreSQL documentation. (MySQL should also work, but is not yet tested/documented). -
Create config and initial user list files:
cd resources/configuration/server cp config.sample config cp users.sample usersEdit
configso thatJDBC_USERis the username (e.g. dbwiki) andJDBC_PASSWORDis that user's password.The
JDBC_URLparameter should be set to point to the database server set up in step 3, using JDBC connection string format. For a local PostgreSQL server running on the default port, theJDBC_URLparameter should be set tojdbc:postgresql://localhost. If the PostgreSQL server you want to use is remote, then changeJDBC_URLto point to the appropriate host instead oflocalhost. -
Change back to the root of the source tree and initialize the database:
cd ../../.. sh create-server.shThis should succeed with no output if everything is configured correctly. You can confirm this by checking that tables such as
_user,_databaseand_templateshave been added to thedbwikidatabase. -
The exciting part: Start the server!
sh start-server.shThis will not work if the PostgreSQL user/password settings are incorrect, or if the core server tables weren't created successfully.
It may also fail if port 8080 is already used for something else on your machine. If so, change
PORTinconfigto an unused port, e.g. 8081.On success, start-server.sh should print out something like:
START SERVER ON ADDRESS /0.0.0.0:8080 AT Wed Feb 23 13:20:25 GMT 2011 -
Test that the server is running correctly by visiting
using Firefox (other web browsers may work but have sometimes had incompatibilities).
-
Once you've confirmed that the server is running correctly, you need to load some data. See LoadingData.
If you want to do this, you should be able to figure out how from the instructions above, using the Windows cmd.exe commands such as create-server.cmd, start-server.cmd etc. instead of the Unix-style shell scripts.
-
After following the above instructions to build and configure DBWiki, you can use the Ant build file to create an Eclipse project (
New Project/Java/Create from ant build file). -
It is possible to create a run configuration within Eclipse to run DBWiki with debugging enabled. To do this:
- set the
Main classtoorg.dbwiki.StartServer - set the
Program argumentstoresources/configuration/server/config - set the
working directoryto thedatabase-wiki/directory (the one containingresourcesas a subdirectory), NOT the workspace default
- set the