Nexchan commited on
Commit
8359093
1 Parent(s): d2256ae

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +5 -18
Dockerfile CHANGED
@@ -50,22 +50,9 @@ RUN apt install -y imagemagick
50
  # Create .ssh directory for Nex user
51
  RUN mkdir /home/Nex/.ssh && chown Nex:Nex /home/Nex/.ssh
52
 
53
- # Switch to Nex user
54
- USER Nex
 
55
 
56
- # Set environment variables for the user
57
- ENV HOME=/home/Nex \
58
- PATH=/home/Nex/.local/bin:$PATH
59
-
60
- # Set the working directory
61
- WORKDIR $HOME/app
62
-
63
- # Copy package.json and package-lock.json files and install dependencies
64
- COPY --chown=Nex package*.json .
65
- RUN npm install
66
-
67
- # Copy the rest of the application code
68
- COPY --chown=Nex . .
69
-
70
- # Start SSH server and code-server
71
- CMD ["sh", "-c", "service ssh start && code-server . --bind-addr 0.0.0.0:7860 --auth none"]
 
50
  # Create .ssh directory for Nex user
51
  RUN mkdir /home/Nex/.ssh && chown Nex:Nex /home/Nex/.ssh
52
 
53
+ # Copy entrypoint script
54
+ COPY entrypoint.sh /entrypoint.sh
55
+ RUN chmod +x /entrypoint.sh
56
 
57
+ # Set the entrypoint script
58
+ ENTRYPOINT ["/entrypoint.sh"]