UNCLASSIFIED

Commit 5c343a88 authored by Andy Maksymowicz's avatar Andy Maksymowicz
Browse files

Merge branch 'development' into 'master'

Permissions issue fix

See merge request !21
parents 55313574 a8b493e0
Pipeline #466861 passed with stages
in 24 minutes and 59 seconds
......@@ -14,6 +14,7 @@ FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG}
ARG PKG=redis
ARG BITNAMI_HOME=/opt/bitnami
ARG REDIS_HOME=${BITNAMI_HOME}/redis
ARG BITNAMI_VOLUME_DIR=/bitnami
ARG REDIS_USER_ID="1001"
ARG REDIS_USER_NAME=${PKG}
......@@ -34,6 +35,7 @@ RUN dnf update -y --nodocs && \
dnf clean all && \
rm -rf /var/cache/dnf && \
mkdir -p ${BITNAMI_HOME} && \
mkdir -p ${BITNAMI_VOLUME_DIR} && \
mkdir /docker-entrypoint-initdb.d
COPY --from=staging /staging ${BITNAMI_HOME}
......@@ -42,7 +44,8 @@ COPY scripts ${BITNAMI_HOME}/scripts
RUN ln -s ${BITNAMI_HOME}/scripts/redis/entrypoint.sh /entrypoint.sh && \
ln -s ${BITNAMI_HOME}/scripts/redis/run.sh /run.sh && \
useradd -u ${REDIS_USER_ID} -g 0 -M -d ${REDIS_HOME} ${REDIS_USER_NAME} && \
chown -R ${REDIS_USER_NAME}:0 ${REDIS_HOME}
chown -R ${REDIS_USER_NAME}:0 ${REDIS_HOME} && \
chown -R ${REDIS_USER_NAME}:0 ${BITNAMI_VOLUME_DIR}
USER ${REDIS_USER_ID}
......@@ -54,4 +57,4 @@ HEALTHCHECK --start-period=3s --timeout=5s --interval=3s --retries=3 \
CMD curl -fs http://localhost:6379 || exit 1
ENTRYPOINT [ "/opt/bitnami/scripts/redis/entrypoint.sh" ]
CMD [ "/opt/bitnami/scripts/redis/run.sh" ]
CMD [ "/opt/bitnami/scripts/redis/run.sh" ]
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment