File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -6,8 +6,7 @@ ENV SSH_PORT=2222 \
66 TZ=UTC \
77 LC_ALL=en_US.UTF-8 \
88 LANG=en_US.UTF-8 \
9- APPUSER_UID=1000 \
10- APP_UID=1654
9+ APPUSER_UID=1000
1110
1211# Copy files in structure /etc/ssh/sshd_config, /opt/startup/init_container.sh /tmp/ssh_setup.sh
1312COPY src/ /
@@ -28,12 +27,4 @@ RUN apk add --no-cache openssh tzdata icu-data-full icu-libs \
2827 --uid=$APPUSER_UID \
2928 --ingroup=appuser \
3029 --disabled-password \
31- appuser \
32- && addgroup \
33- --gid=$APP_UID \
34- app \
35- && adduser \
36- --uid=$APP_UID \
37- --ingroup=app \
38- --disabled-password \
39- app
30+ appuser
Original file line number Diff line number Diff line change @@ -6,7 +6,8 @@ ENV SSH_PORT=2222 \
66 TZ=UTC \
77 LC_ALL=en_US.UTF-8 \
88 LANG=en_US.UTF-8 \
9- APPUSER_UID=1000
9+ APPUSER_UID=1000 \
10+ APP_UID=1654
1011
1112# Copy files in structure /etc/ssh/sshd_config, /opt/startup/init_container.sh /tmp/ssh_setup.sh
1213COPY src/ /
@@ -27,4 +28,12 @@ RUN apk add --no-cache openssh tzdata icu-data-full icu-libs \
2728 --uid=$APPUSER_UID \
2829 --ingroup=appuser \
2930 --disabled-password \
30- appuser
31+ appuser \
32+ && addgroup \
33+ --gid=$APP_UID \
34+ app \
35+ && adduser \
36+ --uid=$APP_UID \
37+ --ingroup=app \
38+ --disabled-password \
39+ app
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1- ARG IMAGE_TAG=6 .0-bullseye-slim
1+ ARG IMAGE_TAG=10 .0-noble
22FROM mcr.microsoft.com/dotnet/aspnet:${IMAGE_TAG} AS base
33
44ENV SSH_PORT=2222 \
55 TZ=UTC \
6- APPUSER_UID=1000 \
7- APP_UID=1654
6+ APPUSER_UID=1000
87
98# Copy files in structure /etc/ssh/sshd_config, /opt/startup/init_container.sh /tmp/ssh_setup.sh
109COPY src/ /
@@ -18,20 +17,4 @@ RUN apt-get update \
1817 && echo "root:Docker!" | chpasswd \
1918 && chmod -R +x /opt/startup \
2019 && (sleep 1;/opt/startup/ssh_setup.sh 2>&1 > /dev/null) \
21- && rm -rf /tmp/* \
22- && addgroup \
23- --gid=$APPUSER_UID \
24- appuser \
25- && adduser \
26- --uid=$APPUSER_UID \
27- --ingroup=appuser \
28- --disabled-password \
29- appuser \
30- && addgroup \
31- --gid=$APP_UID \
32- app \
33- && adduser \
34- --uid=$APP_UID \
35- --ingroup=app \
36- --disabled-password \
37- app
20+ && rm -rf /tmp/*
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1- ARG IMAGE_TAG=10 .0-trixie -slim
1+ ARG IMAGE_TAG=6 .0-bullseye -slim
22FROM mcr.microsoft.com/dotnet/aspnet:${IMAGE_TAG} AS base
33
44ENV SSH_PORT=2222 \
55 TZ=UTC \
6- APPUSER_UID=1000
6+ APPUSER_UID=1000 \
7+ APP_UID=1654
78
89# Copy files in structure /etc/ssh/sshd_config, /opt/startup/init_container.sh /tmp/ssh_setup.sh
910COPY src/ /
@@ -25,4 +26,12 @@ RUN apt-get update \
2526 --uid=$APPUSER_UID \
2627 --ingroup=appuser \
2728 --disabled-password \
28- appuser
29+ appuser \
30+ && addgroup \
31+ --gid=$APP_UID \
32+ app \
33+ && adduser \
34+ --uid=$APP_UID \
35+ --ingroup=app \
36+ --disabled-password \
37+ app
You can’t perform that action at this time.
0 commit comments