X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=near-rt-ric-simulator%2Ftest%2FSTD_1.1.3%2Fbuild_and_start.sh;fp=near-rt-ric-simulator%2Ftest%2FSTD_1.1.3%2Fbuild_and_start.sh;h=1dcacc4b6c06e51eaf8c480aa6b730d0f9594c83;hb=8302f193ed4669cccd75b15512b76b1760fc57db;hp=dd1ac8a7df41743c2c5d90592d1d3dd7e22c4db5;hpb=83a40dbfcf55379fb3912b7473c0d6f7dd03863f;p=sim%2Fa1-interface.git diff --git a/near-rt-ric-simulator/test/STD_1.1.3/build_and_start.sh b/near-rt-ric-simulator/test/STD_1.1.3/build_and_start.sh index dd1ac8a..1dcacc4 100755 --- a/near-rt-ric-simulator/test/STD_1.1.3/build_and_start.sh +++ b/near-rt-ric-simulator/test/STD_1.1.3/build_and_start.sh @@ -17,13 +17,29 @@ # ============LICENSE_END================================================= # -#Script to build and start the container +# Script to build and start the container +# Args: nonsecure|secure +if [ $# -ne 1 ]; then + echo "Usage: ./build_and_start.sh nonsecure|secure" + exit 1 +fi +if [ "$1" != "nonsecure" ] && [ "$1" != "secure" ]; then + echo "Usage: ./build_and_start.sh nonsecure|secure" + exit 1 +fi +echo "Building image" cd ../../ #Build the image docker build -t a1test . -#Run the container in interactive mode -docker run -it -p 8085:8085 -e A1_VERSION=STD_1.1.3 a1test \ No newline at end of file +echo "Starting $1 mode" +if [ $1 == "nonsecure" ]; then + #Run the container in interactive mode, unsecure port + docker run -it -p 8085:8085 -e A1_VERSION=STD_1.1.3 -e REMOTE_HOSTS_LOGGING=1 a1test +else + #Run the container in interactive mode, secure port. + docker run -it -p 8185:8185 -e A1_VERSION=STD_1.1.3 -e REMOTE_HOSTS_LOGGING=1 --read-only --volume "$PWD/certificate:/usr/src/app/cert" a1test +fi \ No newline at end of file