Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Next #183

Merged
merged 5 commits into from
Nov 26, 2023
Merged

Next #183

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 3 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,6 @@ version: "3.1"
services:
peppermint_postgres:
container_name: peppermint_postgres
profiles:
- prod
- dev
- test
image: postgres:latest
restart: always
ports:
Expand All @@ -70,10 +66,6 @@ services:
restart: always
depends_on:
- peppermint_postgres
profiles:
- prod
depends_on:
- postgres
healthcheck:
test: ["CMD", "sh", "-c", "wget --spider $$BASE_URL"]
interval: 30s
Expand All @@ -84,9 +76,11 @@ services:
DB_PASSWORD: "1234"
DB_HOST: "peppermint_postgres"
SECRET: 'peppermint4life'

API_URL: "http://localhost:5003"

volumes:
pgdata:

```

Once this is completed then you can go to your base_url which was added to the compose file and login.
Expand Down
3 changes: 2 additions & 1 deletion apps/client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start"
"start": "next start",
"docker": "next build && next start"
},
"dependencies": {
"@headlessui/react": "^1.4.2",
Expand Down
1 change: 1 addition & 0 deletions docker-compose.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ services:
DB_USERNAME: "peppermint"
DB_PASSWORD: "1234"
DB_HOST: "peppermint_postgres"
SECRET: 'peppermint4life'
API_URL: "http://localhost:5003"

volumes:
Expand Down
5 changes: 3 additions & 2 deletions docker-compose.local.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ services:
build: "."
ports:
- 3000:3000
- 5003:5003
- 5001:5003
restart: always
depends_on:
- peppermint_postgres
Expand All @@ -32,7 +32,8 @@ services:
DB_USERNAME: "peppermint"
DB_PASSWORD: "1234"
DB_HOST: "peppermint_postgres"
API_URL: "http://localhost:5003"
SECRET: 'peppermint4life'
API_URL: "http://localhost:5001"

volumes:
pgdata:
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ services:
DB_USERNAME: "peppermint"
DB_PASSWORD: "1234"
DB_HOST: "peppermint_postgres"
SECRET: 'peppermint4life'
API_URL: "http://localhost:5003"

volumes:
Expand Down
3 changes: 1 addition & 2 deletions dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ COPY apps/api/package*.json ./apps/api/
COPY apps/client/package*.json ./apps/client/
COPY ./ecosystem.config.js ./ecosystem.config.js


RUN npm i -g prisma
RUN npm i -g typescript@latest -g --force

Expand All @@ -23,7 +22,7 @@ RUN cd apps/api && npm install --production
RUN cd apps/api && npm i --save-dev @types/node && npm run build

RUN cd apps/client && yarn install --production --ignore-scripts --prefer-offline --network-timeout 1000000
RUN cd apps/client && yarn add --dev typescript @types/node --network-timeout 1000000 && yarn build
RUN cd apps/client && yarn add --dev typescript @types/node --network-timeout 1000000

FROM node:lts AS runner

Expand Down
2 changes: 1 addition & 1 deletion ecosystem.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ module.exports = {
apps: [
{
name: "client",
script: "npm run start",
script: "npm run docker",
cwd: "apps/client",
instances: "1",
autorestart: true,
Expand Down
Loading
Loading