Skip to content

Commit f2f39ae

Browse files
committed
Modifies addgroup/adduser method
1 parent a349129 commit f2f39ae

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

composer.dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ ARG PHPUSER
66
ENV PHPGROUP=${PHPGROUP}
77
ENV PHPUSER=${PHPUSER}
88

9-
RUN adduser -g ${PHPGROUP} -s /bin/sh -D ${PHPUSER}; exit 0
9+
RUN addgroup --system ${PHPGROUP}; exit 0
10+
RUN adduser --system -G ${PHPGROUP} -s /bin/sh -D ${PHPUSER}; exit 0
1011

1112
WORKDIR /var/www/html

nginx.dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,5 @@ ADD ./nginx/default.conf /etc/nginx/conf.d/
1212

1313
RUN mkdir -p /var/www/html
1414

15-
RUN adduser -g ${NGINXGROUP} -s /bin/sh -D ${NGINXUSER}; exit 0
15+
RUN addgroup --system ${NGINXGROUP}; exit 0
16+
RUN adduser --system -G ${NGINXGROUP} -s /bin/sh -D ${NGINXUSER}; exit 0

php.dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ ARG PHPUSER
66
ENV PHPGROUP=${PHPGROUP}
77
ENV PHPUSER=${PHPUSER}
88

9-
RUN adduser -g ${PHPGROUP} -s /bin/sh -D ${PHPUSER}; exit 0
9+
RUN addgroup --system ${PHPGROUP}; exit 0
10+
RUN adduser --system -G ${PHPGROUP} -s /bin/sh -D ${PHPUSER}; exit 0
1011

1112
RUN mkdir -p /var/www/html
1213

0 commit comments

Comments
 (0)