mirror of
https://github.com/HeyPuter/puter
synced 2024-11-14 22:06:00 +00:00
Update Dockerfile
This commit is contained in:
parent
01baea8b05
commit
3543adfdee
3
.dockerignore
Normal file
3
.dockerignore
Normal file
@ -0,0 +1,3 @@
|
||||
.dockerignore
|
||||
Dockerfile
|
||||
node_modules
|
32
Dockerfile
32
Dockerfile
@ -1,6 +1,30 @@
|
||||
FROM node:hydrogen-alpine
|
||||
WORKDIR /app
|
||||
FROM node:21-alpine
|
||||
|
||||
# Set labels
|
||||
LABEL repo="https://github.com/HeyPuter/puter"
|
||||
LABEL license="AGPL-3.0,https://github.com/HeyPuter/puter/blob/master/LICENSE.txt"
|
||||
LABEL version="v1.2.40-beta"
|
||||
|
||||
# Debugging
|
||||
RUN apk add --no-cache bash # useful for debugging
|
||||
|
||||
# Setup working directory
|
||||
RUN mkdir -p /opt/puter/app
|
||||
WORKDIR /opt/puter/app
|
||||
|
||||
# Add source files
|
||||
# NOTE: This might change (https://github.com/HeyPuter/puter/discussions/32)
|
||||
COPY . .
|
||||
RUN yarn install
|
||||
CMD ["node", "dev-server.js"]
|
||||
|
||||
# Set permissions
|
||||
RUN chown -R node:node /opt/puter/app
|
||||
USER node
|
||||
|
||||
# Install node modules
|
||||
RUN npm cache clean --force \
|
||||
&& npm install
|
||||
|
||||
EXPOSE 4000
|
||||
|
||||
|
||||
CMD [ "npm", "start" ]
|
||||
|
Loading…
Reference in New Issue
Block a user