Mercurial > dive4elements > river
annotate etl/bin/run.sh @ 9751:308a0d822d18 3.2.x
Keep configuration and data in distinct directories
This allows having distinct volumes for configuration and data
(artifact database, generated mapfiles and shapefiles, etc.).
While at it, cleanup MapServer configuration a little bit.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Tue, 11 Oct 2022 11:42:09 +0200 |
parents | 0a5239a1e46e |
children |
rev | line source |
---|---|
4113
f72c253663fc
FYLS/AFT/DIPS: Added start script.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
1 #!/bin/bash |
f72c253663fc
FYLS/AFT/DIPS: Added start script.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
2 |
8835
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
3 APP=org.dive4elements.river.etl.aft.Sync |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
4 |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
5 DIR=`dirname $0` |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
6 DIR=`readlink -f $DIR` |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
7 |
8837
4542d23f98bf
ETL: Add shell parameters for config to run script.
Tom Gottfried <tom@intevation.de>
parents:
8835
diff
changeset
|
8 CONF=${1:-../doc/conf.xml} |
4542d23f98bf
ETL: Add shell parameters for config to run script.
Tom Gottfried <tom@intevation.de>
parents:
8835
diff
changeset
|
9 CONF=$(readlink -f $CONF) |
9726 | 10 LOG4J_CONF=${2:-log4j2.xml} |
8837
4542d23f98bf
ETL: Add shell parameters for config to run script.
Tom Gottfried <tom@intevation.de>
parents:
8835
diff
changeset
|
11 LOG4J_CONF=$(readlink -f $LOG4J_CONF) |
4542d23f98bf
ETL: Add shell parameters for config to run script.
Tom Gottfried <tom@intevation.de>
parents:
8835
diff
changeset
|
12 |
8835
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
13 CLASSPATH= |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
14 for l in `find "$DIR/lib" -name \*.jar -print`; do |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
15 CLASSPATH=$CLASSPATH:$l |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
16 done |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
17 |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
18 export CLASSPATH |
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
19 |
4113
f72c253663fc
FYLS/AFT/DIPS: Added start script.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff
changeset
|
20 exec java \ |
9726 | 21 -Dlog4j2.configurationFile=file://$LOG4J_CONF \ |
8837
4542d23f98bf
ETL: Add shell parameters for config to run script.
Tom Gottfried <tom@intevation.de>
parents:
8835
diff
changeset
|
22 -Dconfig.file=$CONF \ |
8835
d8d71005a210
ETL: use Java 7, include run-script and docs when packaging.
Tom Gottfried <tom@intevation.de>
parents:
5838
diff
changeset
|
23 $APP |