-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathDockerfile
More file actions
31 lines (22 loc) · 716 Bytes
/
Copy pathDockerfile
File metadata and controls
31 lines (22 loc) · 716 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Install steamcmd under the user steam
FROM cm2network/steamcmd:latest
# Install curl
USER root
RUN apt install -y curl
# Install node (under the user steam)
USER steam
ENV NODE_VERSION=v15.14.0
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
ENV NVM_DIR=/home/steam/.nvm
RUN /bin/bash -c "source $NVM_DIR/nvm.sh && nvm install $NODE_VERSION && nvm use --delete-prefix $NODE_VERSION"
ENV PATH="$NVM_DIR/versions/node/$NODE_VERSION/bin:$PATH"
RUN mkdir -p /home/steam/Steam/steamapps/workshop/content
# Copy project files
RUN mkdir /home/steam/app
WORKDIR /home/steam/app
RUN ls -la
COPY --chown=steam . .
RUN ls -la
RUN whoami
RUN npm install --production
CMD npm start