From df403bd1bfa5a4bcecfc12ceaaa2ef49885950a4 Mon Sep 17 00:00:00 2001 From: Murat Ugur Eminoglu Date: Sat, 16 Sep 2023 08:15:29 +0300 Subject: [PATCH] Refactor Dockerfile for conditional AntMediaServer and LicenseKey installation --- docker/Dockerfile_Process | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docker/Dockerfile_Process b/docker/Dockerfile_Process index 1f3f92e5..dd1534af 100644 --- a/docker/Dockerfile_Process +++ b/docker/Dockerfile_Process @@ -19,17 +19,17 @@ RUN cd home \ && wget https://raw.githubusercontent.com/ant-media/Scripts/${BranchName}/install_ant-media-server.sh \ && chmod 755 install_ant-media-server.sh -RUN cd home \ +RUN cd /home \ && pwd \ && if [ -n "$AntMediaServer" ]; then \ ./install_ant-media-server.sh -i ${AntMediaServer} -s false; \ - fi \ - && if [ -n "$LicenseKey" ]; then \ + elif [ -n "$LicenseKey" ]; then \ ./install_ant-media-server.sh -l ${LicenseKey} -s false; \ + else \ + echo "Both AntMediaServer and LicenseKey arguments are not provided. Aborting the build process."; \ + exit 1; \ fi - - # Options # -g: Use global(Public) IP in network communication. Its value can be true or false. Default value is false. #