Skip to content
Snippets Groups Projects
Commit 03087c43 authored by Hannes Feldt's avatar Hannes Feldt
Browse files

add network option

parent 550edcb7
No related branches found
No related tags found
5 merge requests!752Resolve L2SS-1525 "Migrate minio",!751Resolve L2SS-1340 "Deploy monitoring to nomad",!750Resolve L2SS-1341 "Migrate tango2nomad",!749Resolve L2SS-1342 "Migrate jupyter",!710L2SS-1341: Migrate tango to nomad
...@@ -4,15 +4,18 @@ ...@@ -4,15 +4,18 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
# #
# defaults
network="station"
# list of arguments expected in the input # list of arguments expected in the input
optstring_long="help,load,update,dump" optstring_long="help,load,update,dump,file,network::"
optstring="hlud" optstring="hludf:n::"
options=$(getopt -l ${optstring_long} -o ${optstring} -- "$@") options=$(getopt -l ${optstring_long} -o ${optstring} -- "$@")
eval set -- "$options" eval set -- "$options"
while true; do while true; do
case ${1} in case ${1} in
-h|--help) -h|--help)
...@@ -31,6 +34,10 @@ while true; do ...@@ -31,6 +34,10 @@ while true; do
echo "Dump config" echo "Dump config"
action="dump" action="dump"
;; ;;
-n|--network)
shift
network="$1"
;;
--) --)
shift shift
break;; break;;
...@@ -42,7 +49,8 @@ if [ -z "$TAG" ]; then ...@@ -42,7 +49,8 @@ if [ -z "$TAG" ]; then
TAG="latest" TAG="latest"
fi fi
docker_args=(run --rm -e "TANGO_HOST=$TANGO_HOST" --network=station -i) echo "Use docker network '$network'"
docker_args=(run --rm -e "TANGO_HOST=$TANGO_HOST" --network="$network" -i)
docker_image="git.astron.nl:5000/lofar2.0/tango/dsconfig:$TAG" docker_image="git.astron.nl:5000/lofar2.0/tango/dsconfig:$TAG"
if [[ -n "$DNS" ]]; then if [[ -n "$DNS" ]]; then
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment