Add features
This commit is contained in:
19
Dockerfile
Normal file
19
Dockerfile
Normal file
@@ -0,0 +1,19 @@
|
||||
FROM node:lts-alpine
|
||||
|
||||
# Create app directory and copy the app
|
||||
WORKDIR /app
|
||||
COPY . .
|
||||
|
||||
# Run as non-root user
|
||||
RUN addgroup -g 1001 -S nodejs
|
||||
RUN adduser -S nodejs -u 1001
|
||||
RUN chown -R nodejs:nodejs /app
|
||||
USER nodejs
|
||||
|
||||
# Install
|
||||
RUN npm install
|
||||
|
||||
# Start the app
|
||||
ENTRYPOINT ["npm", "run"]
|
||||
CMD ["start"]
|
||||
|
||||
Reference in New Issue
Block a user