privateone commited on
Commit
ca36264
·
verified ·
1 Parent(s): 2b5e266

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +12 -2
Dockerfile CHANGED
@@ -22,7 +22,17 @@ RUN curl -sSL https://ngrok-agent.s3.amazonaws.com/ngrok.asc \
22
  && apt-get update \
23
  && apt-get install -y ngrok \
24
  && rm -rf /var/lib/apt/lists/*
 
 
 
 
 
25
 
 
 
 
 
 
26
  # Install socat and openssl for certificate generation
27
  # RUN apk add --no-cache socat openssl
28
 
@@ -40,8 +50,8 @@ RUN curl -sSL https://ngrok-agent.s3.amazonaws.com/ngrok.asc \
40
  # RUN chmod 600 /etc/turn/certs/*
41
 
42
  # Copy your custom entrypoint script
43
- RUN mkdir -p /custom-entrypoint /ngrok2
44
- COPY ngrok.yml /ngrok2/ngrok.yml
45
 
46
  COPY custom-entrypoint.sh /custom-entrypoint/entrypoint.sh
47
  RUN chmod +x /custom-entrypoint/entrypoint.sh ngrok2/ngrok.yml
 
22
  && apt-get update \
23
  && apt-get install -y ngrok \
24
  && rm -rf /var/lib/apt/lists/*
25
+
26
+ RUN adduser --disabled-password --gecos '' --shell /bin/bash user \
27
+ && chown -R user:user /app
28
+ RUN echo "user ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/90-user
29
+ USER user
30
 
31
+ # All users can use /home/user as their home directory
32
+ ENV HOME=/home/user
33
+ RUN mkdir $HOME/.cache $HOME/.config \
34
+ && chmod -R 777 $HOME
35
+
36
  # Install socat and openssl for certificate generation
37
  # RUN apk add --no-cache socat openssl
38
 
 
50
  # RUN chmod 600 /etc/turn/certs/*
51
 
52
  # Copy your custom entrypoint script
53
+ RUN mkdir -p /custom-entrypoint ~/.ngrok2
54
+ COPY ngrok.yml ~/.ngrok2/ngrok.yml
55
 
56
  COPY custom-entrypoint.sh /custom-entrypoint/entrypoint.sh
57
  RUN chmod +x /custom-entrypoint/entrypoint.sh ngrok2/ngrok.yml