Skip to content

Commit

Permalink
Change FE dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
Sampy147 committed Nov 16, 2023
1 parent 68a903c commit 82a6ab0
Show file tree
Hide file tree
Showing 4 changed files with 80 additions and 2 deletions.
11 changes: 11 additions & 0 deletions backend/question-service2/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
DATABASE_URL=postgresql://admin:password@postgres_question_service:5432/postgres
POSTGRES_USER=admin
POSTGRES_PASSWORD=password
POSTGRES_DB=postgres
SERVER_PORT=5000

GCP_DATABASE_URL=postgresql://a:,-A%q$9@localhost/db?host=/cloudsql/cs3219-c0869:asia-southeast1:mdb
KAFKA_BROKER_URL=pkc-ldvr1.asia-southeast1.gcp.confluent.cloud:9092
KAFKA_BROKER_USERNAME=AFPPH42JG4Y4MZ5Z
KAFKA_BROKER_PASSWORD=uRHN+aZdfsRhuNrsDHlAHrWYo8D4QEV77RhIIzmzSHNB9ngmTuh6d6Kn75ZkHxGI
NODE_ENV=production
11 changes: 11 additions & 0 deletions backend/socket-service/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
DATABASE_URL=postgresql://admin:password@postgres_socket_service:5432/postgres
POSTGRES_USER=admin
POSTGRES_PASSWORD=password
POSTGRES_DB=postgres
SERVER_PORT=5000

GCP_DATABASE_URL=postgresql://a:,-A%q$9@localhost/db?host=/cloudsql/cs3219-c0869:asia-southeast1:mdb
KAFKA_BROKER_URL=pkc-ldvr1.asia-southeast1.gcp.confluent.cloud:9092
KAFKA_BROKER_USERNAME=AFPPH42JG4Y4MZ5Z
KAFKA_BROKER_PASSWORD=uRHN+aZdfsRhuNrsDHlAHrWYo8D4QEV77RhIIzmzSHNB9ngmTuh6d6Kn75ZkHxGI
NODE_ENV=production
56 changes: 56 additions & 0 deletions backend/user-service2/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# PORT=5008
# USE_DOCKER_DB=false
# DATABASE_URL=postgresql://postgres:cs3219assignmentgroup31@postgres_user_service:5432/postgres
# POSTGRES_USER=postgres
# POSTGRES_PASSWORD=cs3219assignmentgroup31
# POSTGRES_DB=postgres
# SERVER_PORT=5000

# GCP_DATABASE_URL=postgresql://a:,-A%q$9@localhost/db?host=/cloudsql/cs3219-c0869:asia-southeast1:mdb
# KAFKA_BROKER_URL=pkc-ldvr1.asia-southeast1.gcp.confluent.cloud:9092
# KAFKA_BROKER_USERNAME=AFPPH42JG4Y4MZ5Z
# KAFKA_BROKER_PASSWORD=uRHN+aZdfsRhuNrsDHlAHrWYo8D4QEV77RhIIzmzSHNB9ngmTuh6d6Kn75ZkHxGI
# NODE_ENV=production

DATABASE_URL=postgresql://admin:password@postgres_user_service:5432/postgres
POSTGRES_USER=admin
POSTGRES_PASSWORD=password
POSTGRES_DB=postgres
SERVER_PORT=5000

GCP_DATABASE_URL=postgresql://a:,-A%q$9@localhost/db?host=/cloudsql/cs3219-c0869:asia-southeast1:mdb
KAFKA_BROKER_URL=pkc-ldvr1.asia-southeast1.gcp.confluent.cloud:9092
KAFKA_BROKER_USERNAME=AFPPH42JG4Y4MZ5Z
KAFKA_BROKER_PASSWORD=uRHN+aZdfsRhuNrsDHlAHrWYo8D4QEV77RhIIzmzSHNB9ngmTuh6d6Kn75ZkHxGI
NODE_ENV=production

# PORT=5008
# USE_DOCKER_DB=false

# DATABASE_URL=postgresql://admin:password@postgres_user_service:5432/postgres
# POSTGRES_USER=admin
# POSTGRES_PASSWORD=password
# POSTGRES_DB=postgres
# SERVER_PORT=5000

# GCP_DATABASE_URL=postgresql://a:,-A%q$9@localhost/db?host=/cloudsql/cs3219-c0869:asia-southeast1:mdb
# KAFKA_BROKER_URL=pkc-ldvr1.asia-southeast1.gcp.confluent.cloud:9092
# KAFKA_BROKER_USERNAME=AFPPH42JG4Y4MZ5Z
# KAFKA_BROKER_PASSWORD=uRHN+aZdfsRhuNrsDHlAHrWYo8D4QEV77RhIIzmzSHNB9ngmTuh6d6Kn75ZkHxGI
# NODE_ENV=production


# PORT=5008
# USE_DOCKER_DB=false
# DATABASE_URL=postgresql://postgres:cs3219assignmentgroup31@postgres_user_service:5432/postgres
# POSTGRES_USER=postgres
# POSTGRES_PASSWORD=cs3219assignmentgroup31
# POSTGRES_DB=postgres
# SERVER_PORT=5000

# DATABASE_URL=postgresql://admin:password@postgres_user_test_service:5431/postgres
# POSTGRES_USER=admin
# POSTGRES_PASSWORD=password
# POSTGRES_DB=postgres
# SERVER_PORT=5000
# NODE_ENV=test
4 changes: 2 additions & 2 deletions frontend/Dockerfile.prod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:20-alpine AS builder
FROM --platform=linux/amd64 node:20-alpine AS builder
WORKDIR /app
COPY package.json yarn.lock* package-lock.json* pnpm-lock.yaml* ./
RUN \
Expand All @@ -11,7 +11,7 @@ RUN \
COPY . .
RUN yarn build

FROM nginx:alpine
FROM --platform=linux/amd64 nginx:alpine
WORKDIR /usr/share/nginx/html
RUN rm -rf ./*
COPY --from=builder /app/dist ./
Expand Down

0 comments on commit 82a6ab0

Please sign in to comment.