Spaces:
Sleeping
Sleeping
fix: use openssl passwd instead of chpasswd for user creation
Browse fileschpasswd fails with PAM error in Docker build. Use useradd -p with
openssl passwd -6 to set password directly.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Dockerfile +1 -2
Dockerfile
CHANGED
|
@@ -36,8 +36,7 @@ RUN dpkg-query -W -f='${Package}\n' | sort > /etc/base-packages.list
|
|
| 36 |
RUN ssh-keygen -A
|
| 37 |
|
| 38 |
# User account (for SSH login); container runs as root for system persistence
|
| 39 |
-
RUN
|
| 40 |
-
RUN echo "user:huggingrun" | chpasswd
|
| 41 |
RUN mkdir -p /data && chown 1000:1000 /data
|
| 42 |
|
| 43 |
# nginx + bridge + startup scripts
|
|
|
|
| 36 |
RUN ssh-keygen -A
|
| 37 |
|
| 38 |
# User account (for SSH login); container runs as root for system persistence
|
| 39 |
+
RUN useradd -m -u 1000 -s /bin/bash -p "$(openssl passwd -6 huggingrun)" user 2>/dev/null || true
|
|
|
|
| 40 |
RUN mkdir -p /data && chown 1000:1000 /data
|
| 41 |
|
| 42 |
# nginx + bridge + startup scripts
|