diff --git a/docker/demo/Dockerfile b/docker/demo/Dockerfile index ca613464..ff5d69c5 100644 --- a/docker/demo/Dockerfile +++ b/docker/demo/Dockerfile @@ -1,11 +1,11 @@ FROM alpine/git -ARG GIT_TAG +ARG SEBSERVER_VERSION WORKDIR /demo -RUN if [ "x$arg" = "x" ] ; \ +RUN if [ "x${SEBSERVER_VERSION}" = "x" ] ; \ then git clone --depth 1 https://github.com/SafeExamBrowser/seb-server.git ; \ - else git clone -b "$GIT_TAG" --depth 1 https://github.com/SafeExamBrowser/seb-server.git ; fi + else git clone -b "v$SEBSERVER_VERSION" --depth 1 https://github.com/SafeExamBrowser/seb-server.git ; fi FROM maven:3.5-jdk-8-alpine @@ -28,10 +28,10 @@ ENV GUICLIENT_PWD="[TO_SET]" ENV INTERNAL_PWD="[TO_SET]" WORKDIR /demo -COPY --from=1 /demo/target/seb-server-"$SEBSERVER_VERSION".jar /demo +COPY --from=1 /demo/target/seb-server-"$SEBSERVER_VERSION"-SNAPSHOT.jar /demo ENTRYPOINT ["sh", "-c"] -CMD ["java -jar seb-server-${SEBSERVER_VERSION}.jar --server.address=${SERVER_ADDRESS} --server.port=${SERVER_PORT} --spring.config.location=classpath:/config/ --datastore.mariadb.server.address=${DBSERVER_ADDRESS} --datastore.mariadb.server.port${DBSERVER_PORT} --spring.profiles.active=demo --spring.datasource.password=${DBSERVER_PWD} --sebserver.webservice.api.admin.clientSecret=${GUICLIENT_PWD} --sebserver.webservice.internalSecret=${INTERNAL_PWD}"] +CMD ["java -jar seb-server-${SEBSERVER_VERSION}-SNAPSHOT.jar --server.address=${SERVER_ADDRESS} --server.port=${SERVER_PORT} --spring.config.location=classpath:/config/ --datastore.mariadb.server.address=${DBSERVER_ADDRESS} --datastore.mariadb.server.port${DBSERVER_PORT} --spring.profiles.active=demo --spring.datasource.password=${DBSERVER_PWD} --sebserver.webservice.api.admin.clientSecret=${GUICLIENT_PWD} --sebserver.webservice.internalSecret=${INTERNAL_PWD}"] EXPOSE 8080 \ No newline at end of file diff --git a/docker/demo/docker-compose.yml b/docker/demo/docker-compose.yml index 8e686b50..94b7ccd1 100644 --- a/docker/demo/docker-compose.yml +++ b/docker/demo/docker-compose.yml @@ -14,8 +14,8 @@ services: build: context: . args: - - GIT_TAG=v0.4.1-beta - - SEBSERVER_VERSION=0.4.1-SNAPSHOT + - GIT_TAG= + - SEBSERVER_VERSION=0.4.1-beta container_name: seb-server environment: - SERVER_ADDRESS=0.0.0.0