We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 22835d5 commit c55b4a0Copy full SHA for c55b4a0
Dockerfile
@@ -0,0 +1,15 @@
1
+FROM node:16.17.0-alpine
2
+WORKDIR '/app'
3
+
4
+COPY package.json .
5
+RUN npm install
6
+COPY . .
7
8
+CMD ["npm","run","dev"]
9
10
11
12
+# if facing error while building image, paste there two command in terminal.
13
14
+# export DOCKER_BUILDKIT=0
15
+#export COMPOSE_DOCKER_CLI_BUILD=0
docker-compose.yaml
@@ -0,0 +1,20 @@
+version: "3"
+services:
+ react-app:
+ restart: always
+ build:
+ context: ./
+ dockerfile: Dockerfile
+ image: amazon-clone
+ stdin_open: true
+ ports:
+ - "3000:3000"
+ networks:
+ - app
+ volumes:
+ - ./src:/app/src
16
+ - ./app/node_modules
17
18
+networks:
19
+ app:
20
+ driver: bridge
0 commit comments