diff --git a/.github/workflows/push-trigger.yml b/.github/workflows/push-trigger.yml index c9f75851..ac620f04 100644 --- a/.github/workflows/push-trigger.yml +++ b/.github/workflows/push-trigger.yml @@ -25,8 +25,6 @@ jobs: strategy: matrix: include: - - SERVICE_LOCATION: 'keycloak-jboss' - SERVICE_NAME: 'mosip-jboss-keycloak' - SERVICE_LOCATION: 'keycloak-init' SERVICE_NAME: 'keycloak-init' - SERVICE_LOCATION: 'keycloak-artemis' diff --git a/keycloak-artemis/Dockerfile b/keycloak-artemis/Dockerfile index d547c20a..6e89c0fe 100644 --- a/keycloak-artemis/Dockerfile +++ b/keycloak-artemis/Dockerfile @@ -30,8 +30,6 @@ RUN chmod +x /usr/sbin/install_packages && chmod g+rwX /opt/bitnami && \ # Install required system packages and dependencies RUN . /usr/sbin/install_packages acl ca-certificates curl gzip libaio1 libc6 procps rsync tar zlib1g -USER 1001 - ENTRYPOINT [ "/opt/bitnami/scripts/keycloak/entrypoint.sh" ] CMD [ "/opt/bitnami/scripts/keycloak/run.sh" ] diff --git a/keycloak-init/Dockerfile b/keycloak-init/Dockerfile index 53b4461c..e7ef02bd 100644 --- a/keycloak-init/Dockerfile +++ b/keycloak-init/Dockerfile @@ -11,26 +11,18 @@ LABEL build_time=${BUILD_TIME} # can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user=mosip - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_group=mosip - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_uid=1001 - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_gid=1001 -# install packages and create user -RUN apt-get -y update \ -&& groupadd -g ${container_user_gid} ${container_user_group} \ -&& useradd -u ${container_user_uid} -g ${container_user_group} -s /bin/sh -m ${container_user} - COPY requirements.txt . -RUN pip3 install -r requirements.txt -# change permissions of file inside working dir -RUN chown -R ${container_user}:${container_user} /home/${container_user} +## install packages, create user and change permissions of file inside working dir +RUN apt-get -y update \ +&& groupadd -g ${container_user_gid} ${container_user_group} \ +&& useradd -u ${container_user_uid} -g ${container_user_group} -s /bin/sh -m ${container_user} \ +&& pip3 install -r requirements.txt \ +&& chown -R ${container_user}:${container_user} /home/${container_user} # select container user for all tasks USER ${container_user_uid}:${container_user_gid} diff --git a/keycloak-jboss/Dockerfile b/keycloak-jboss/Dockerfile index 66d51974..f666cc22 100644 --- a/keycloak-jboss/Dockerfile +++ b/keycloak-jboss/Dockerfile @@ -20,3 +20,10 @@ ADD --chown=jboss:root ./standalone/ ./standalone RUN cp -R ./standalone/deployments/* /opt/jboss/keycloak/standalone/deployments +#ARG container_user=mosip +#ARG container_user_group=mosip +#ARG container_user_uid=1001 +#ARG container_user_gid=1001 +#WORKDIR /home/${container_user} +#RUN chown -R ${container_user}:${container_user} /home/${container_user} +#USER ${container_user_uid}:${container_user_gid}