forked from OpenRoberta/openroberta-lab
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ora-help.txt
43 lines (36 loc) · 3.81 KB
/
ora-help.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
Please read the README.md
Top level in the git repository is a script 'ora.sh' to be used from the command line to configure the OpenRoberta application.
Remarks about the database:
The database may be run in 'embedded' mode. This is for local test/debug:
- the DATABASEURL is "jdbc:hsqldb:file:$DB_PARENTDIR/$DB_NAME;ifexists=true"
- the database is locked by the process accessing the database. Thus no concurrent access (with a sql client) is possible.
The database may be run in 'server' mode. This is for the test and prod server, including small systems as the RaspberryPi
- the DATABASEURL is "jdbc:hsqldb:hsql://localhost/$DB_NAME". On a test server the database name usually is db-ora-SERVER-NAME (server name is e.g. test, develop, dev1,...,dev9
- you can get access to the database used by the server concurrently with a sql client. Be careful NOT to block the server by your sql
Commands of the ora.sh script:
help get help (this text)
export INSTALLATION-DIR [gzip] create a self-contained installation. The INSTALLATION-DIR must NOT exist.
Parameter 'gzip' compresses in directory staticResources suitable files (as *.js, *.css, etc.) to save bandwith when staticResources are loaded.
You are responsible to copy a usable database into directory 'db-<serverVersion>'.
In the INSTALLATION-DIR is the admin script './admin.sh'. Use './admin.sh start-embedded-server' to start (on small systems as RaspberryPI)
a server with embedded database. The script detects a database from an earlier versions and upgrades them to the actual version. If NO database
at all is found, a empty database is created. Run './admin.sh help' for more administration commands.
create-empty-db create an empty database at path $DB_PARENTDIR/$DB_NAME, usually ./OpenRobertaServer/db-embedded. An existing datatbase is NOT overwritten.
start-from-git [-rdbg] [{path-to-crosscompiler-resources}]
if a developer wants to start the server from a Git working tree in embedded mode (that is fine for tests), use this command.
Note, that running the server from an IDE as eclipse is EASIER. You need a valid database. Command 'createEmptydb' creates it.
if '-rdbg' is used, a remote debug session (e.g. from an IDE as Eclipse) can be attached to the server (on port 8000).
Only if you want to test crosscompiler calls, you need the path to the crosscompiler resources directory.
The following commands are used by admins of the test and prod server. These systems are running as docker instances. See Docker/README.md for details.
the base-dir of the docker setup is usually '/data/openroberta-lab'
new-test-setup {base-dir}
creates a new test server setup in {base-dir}. {base-dir} must not exist. Afterwards you have to edit '{base-dir}/config.sh' CAREFULLY.
Needs root privileges. Must be executed on a test machine from an UP-TO-DATE git repository.
new-server-in-test-setup {base-dir} {server-name}
creates a server in the existing test server setup '{base-dir}'. The dirs '{base-dir}/server/{server-name}' and '{base-dir}/db/{server-name}' must not exist.
Afterwards you have to edit '{base-dir}/server/{server-name}/decl.sh' CAREFULLY and to think about whether an empty database is ok or not.
In '{base-dir}/config.sh' {server-name} can be added to the variables SERVERS, AUTODEPLOY and DATABASES.
Needs root privileges. Must be executed on a test machine from an UP-TO-DATE git repository.
update-test-setup [{base-dir}]
expects the test server setup in {base-dir}. Copies all resources from the git-dir 'Docker/openroberta/conf'
into {base-dir}/conf. Needs root privileges. Must be executed on a test machine from an UP-TO-DATE git repository.