Fred808 commited on
Commit
c2d66b5
·
verified ·
1 Parent(s): b9d804e

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +8 -7
Dockerfile CHANGED
@@ -6,20 +6,21 @@ RUN apt-get update && apt-get install -y \
6
  curl \
7
  && rm -rf /var/lib/apt/lists/*
8
 
9
- # Add SSH/Dante config
 
 
 
10
  COPY ssh-config/sshd_config /etc/ssh/sshd_config
11
- COPY socks5-config/danted.conf /etc/danted.conf
12
- RUN chmod 600 /etc/ssh/sshd_config && chmod 644 /etc/danted.conf
13
 
14
- # Ensure SSH can run
15
- RUN mkdir -p /var/run/sshd && ssh-keygen -A
16
 
17
- # Setup
18
  WORKDIR /app
19
  COPY . /app
20
  RUN chmod +x /app/entrypoint.sh
21
 
22
  EXPOSE 22 1080
23
- USER root
24
 
25
  ENTRYPOINT ["/app/entrypoint.sh"]
 
6
  curl \
7
  && rm -rf /var/lib/apt/lists/*
8
 
9
+ # Create required dirs
10
+ RUN mkdir -p /var/run/sshd
11
+
12
+ # Copy configs with root access
13
  COPY ssh-config/sshd_config /etc/ssh/sshd_config
14
+ RUN chmod 600 /etc/ssh/sshd_config
 
15
 
16
+ # Set user to root (important!)
17
+ USER root
18
 
19
+ # Copy rest of the app
20
  WORKDIR /app
21
  COPY . /app
22
  RUN chmod +x /app/entrypoint.sh
23
 
24
  EXPOSE 22 1080
 
25
 
26
  ENTRYPOINT ["/app/entrypoint.sh"]