blob: 0512944dddf22d473106e43f8cf8e4da79b1d4e7 [file] [log] [blame]
Instrumental32cdd552018-07-19 13:29:32 -05001#!/bin/bash
2. ./d.props
3
Instrumental94053612018-10-08 11:27:18 -05004DOCKER=${DOCKER:=docker}
Instrumentalab502672018-08-20 14:31:35 -05005function run_it() {
Instrumental94053612018-10-08 11:27:18 -05006 $DOCKER run $@ \
7 -v "aaf_config:$CONF_ROOT_DIR" \
Instrumental32cdd552018-07-19 13:29:32 -05008 --add-host="$HOSTNAME:$HOST_IP" \
9 --add-host="aaf.osaaf.org:$HOST_IP" \
Instrumental54883b42018-09-25 07:56:54 -050010 --env HOSTNAME=${HOSTNAME} \
Instrumental32cdd552018-07-19 13:29:32 -050011 --env AAF_ENV=${AAF_ENV} \
12 --env AAF_REGISTER_AS=${AAF_REGISTER_AS} \
Instrumental93871ff2018-10-15 07:37:28 -050013 --env AAF_LOCATOR_AS=${AAF_LOCATOR_AS} \
Instrumental32cdd552018-07-19 13:29:32 -050014 --env LATITUDE=${LATITUDE} \
15 --env LONGITUDE=${LONGITUDE} \
Instrumental196000b2018-10-05 19:30:59 -050016 --env CASS_HOST=${CASS_HOST} \
17 --env CASSANDRA_CLUSTER=${CASSANDRA_CLUSTER} \
18 --env CASSANDRA_USER=${CASSANDRA_USER} \
19 --env CASSANDRA_PASSWORD=${CASSANDRA_PASSWORD} \
20 --env CASSANDRA_PORT=${CASSANDRA_PORT} \
Instrumental32cdd552018-07-19 13:29:32 -050021 --name aaf_config_$USER \
Instrumentale44d2f72018-08-16 17:22:45 -050022 $PREFIX${ORG}/${PROJECT}/aaf_config:${VERSION} \
Instrumentalab502672018-08-20 14:31:35 -050023 /bin/bash $PARAMS
24}
25
Instrumentalab502672018-08-20 14:31:35 -050026PARAMS="$@"
Instrumental5ccce032018-11-02 13:12:33 -050027if [ -z "$PARAMS" ]; then
28 run_it --rm
29else
Instrumentalab502672018-08-20 14:31:35 -050030 run_it -it --rm
31fi
32