Skip to content

Commit

Permalink
Merge pull request #488 from FIRSTIsrael/LEMS-472-mongo-hosted
Browse files Browse the repository at this point in the history
Revert back to external mongodb
  • Loading branch information
itamaroryan authored May 5, 2024
2 parents 2b5751e + de558bf commit 372fa40
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 12 deletions.
9 changes: 4 additions & 5 deletions apps/backend/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,10 @@ RUN addgroup -S lems && adduser -S backend -G lems
COPY dist/apps/backend backend
RUN chown -R backend:lems .

# Add when mongo goes back to external
# ARG MONGO_CA_CERTIFICATE
# ENV MONGO_CA_CERTIFICATE=$MONGO_CA_CERTIFICATE
# RUN echo $MONGO_CA_CERTIFICATE > /root/mongo-ca-certificate.crt
# RUN chown backend:lems /root/mongo-ca-certificate.crt
ARG MONGO_CA_CERTIFICATE
ENV MONGO_CA_CERTIFICATE=$MONGO_CA_CERTIFICATE
RUN echo $MONGO_CA_CERTIFICATE > /root/mongo-ca-certificate.crt
RUN chown backend:lems /root/mongo-ca-certificate.crt

# See here: https://pptr.dev/troubleshooting#running-on-alpine
# Installs latest Chromium (100) package.
Expand Down
9 changes: 2 additions & 7 deletions compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ services:
DIGITALOCEAN_SECRET: ${DIGITALOCEAN_SECRET}
JWT_SECRET: ${JWT_SECRET}
DASHBOARD_JWT_SECRET: ${DASHBOARD_JWT_SECRET}
MONGODB_URI: ${MONGODB_URI} # Change in GitHub when mongo goes back to external
# MONGO_CA_CERTIFICATE: ${MONGO_CA_CERTIFICATE} # Add when mongo goes back to external
MONGODB_URI: ${MONGODB_URI}
MONGO_CA_CERTIFICATE: ${MONGO_CA_CERTIFICATE}
RECAPTCHA_SECRET_KEY: ${RECAPTCHA_SECRET_KEY}
DIGITALOCEAN_ENDPOINT: ${DIGITALOCEAN_ENDPOINT}
DIGITALOCEAN_SPACE: ${DIGITALOCEAN_SPACE}
Expand All @@ -20,7 +20,6 @@ services:
- '3333:3333'
networks:
- lems-network
- mongonet # Remove when mongo goes back to external
restart: always

frontend:
Expand All @@ -46,7 +45,3 @@ services:
networks:
lems-network:
driver: bridge
# This network was created externally for Mongo 7 support.
# Remove the network from prod and this file before deploying with external Mongo again.
mongonet:
external: true

0 comments on commit 372fa40

Please sign in to comment.