Skip to content

Commit

Permalink
Fixed docker issues
Browse files Browse the repository at this point in the history
  • Loading branch information
foyzulkarim committed Jul 22, 2021
1 parent 8cc0c0b commit 537274f
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ To test the APIs, we can reuse the postman collection. Open `docs/rbac-mern-boil
| ------- | ----------------- | ---------------------------------------------------- |
| root | `npm run build` | Builds the containers |
| root | `npm run start` | Start the projects and database in docker containers |
|root|`docker exec -it appserver /bin/sh` then `npm run db:seed`|Executes seed products inside container|
| server | `npm i` | Install server side dependencies |
| server | `npm run db:up` | Start the database in a docker container |
| server | `npm run db:seed` | Seed products data into database |
Expand Down
1 change: 1 addition & 0 deletions client/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules
2 changes: 1 addition & 1 deletion client/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:latest as build
FROM node:lts-alpine as build
WORKDIR /usr/src/app
ENV PATH /usr/src/app/node_modules/.bin:$PATH
COPY package*.json ./
Expand Down
1 change: 1 addition & 0 deletions server/.dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
node_modules
2 changes: 1 addition & 1 deletion server/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:latest
FROM node:lts-alpine
WORKDIR /usr/src/app
COPY package*.json ./
ENV NODE_ENV=production
Expand Down

0 comments on commit 537274f

Please sign in to comment.