File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed
Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 22
33DEV=0
44PUSH=1
5+ RUNCONTAINER=0
56# make dockerignore from .gitignore
67cp .gitignore .dockerignore
78for option in " $@ " ; do
@@ -12,6 +13,10 @@ for option in "$@"; do
1213 -n|--no-push)
1314 PUSH=0
1415 ;;
16+ -r|--run)
17+ echo " Run the container after building it."
18+ RUNCONTAINER=1
19+ ;;
1520 --help|--info|--h)
1621 echo " Build and push the current repository state into containers and publish them to"
1722 echo " gcr.io/diamond-privreg/daq-config-server/<container-name> ready for deployment."
@@ -21,6 +26,7 @@ for option in "$@"; do
2126 echo " "
2227 exit 0
2328 ;;
29+
2430 -* |--* )
2531 echo " Unknown option ${option} . Use --help for info on option usage."
2632 exit 1
@@ -61,3 +67,8 @@ if [ $PUSH -gt 0 ]; then
6167 podman tag $MAIN_CONTAINER_NAME $MAIN_CONTAINER_TAG
6268 podman push $MAIN_CONTAINER_NAME $MAIN_CONTAINER_TAG
6369fi
70+
71+ if [ $RUNCONTAINER -gt 0 ]; then
72+ echo " Running container ${MAIN_CONTAINER_NAME} ..."
73+ podman run -d --name $MAIN_CONTAINER_NAME -p 8555:8555 $MAIN_CONTAINER_NAME
74+ fi
You can’t perform that action at this time.
0 commit comments