We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 41179c4 commit 4cd29afCopy full SHA for 4cd29af
Dockerfile
@@ -1,16 +1,17 @@
1
-FROM node:alpine
+FROM node:10.18.1
2
3
# Create work directory
4
WORKDIR /usr/src/app
5
6
-# Install runtime dependencies
7
-RUN npm install yarn -g
8
-
9
# Copy app source to work directory
10
COPY . /usr/src/app
11
12
# Install app dependencies
13
RUN yarn install
14
15
-# Build and run the app
16
-CMD npm start serve
+# Build app
+RUN npm start build
+
+# Run app
+ENTRYPOINT ["npm", "start"]
17
docker-compose.yml
@@ -0,0 +1,13 @@
+version: '3.7'
+services:
+ app:
+ build:
+ dockerfile: ./Dockerfile
+ context: .
+ restart: always
+ container_name: app
+ volumes:
+ - ./.env:/app/.env
+ ports:
+ - "3000:3000"
0 commit comments