Skip to content

Commit

Permalink
Setup /docs in Nginx
Browse files Browse the repository at this point in the history
  • Loading branch information
menghif committed Mar 31, 2022
1 parent d6c4279 commit 68f59b4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 11 deletions.
9 changes: 4 additions & 5 deletions config/nginx.conf.development.template
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,10 @@ http {
proxy_pass http://planet:9876;
}

location /docs {
root /usr/share/nginx/html;
}

# Static next.js front-end
location / {
# Directory from which we serve Next's static content
Expand Down Expand Up @@ -179,9 +183,4 @@ http {
}
}
}
server {
listen 4631 default_server;
server_name localhost;
root /usr/share/nginx/html;
}
}
1 change: 0 additions & 1 deletion docker/development.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ services:
- ../config/nginx.conf.development.template:/etc/nginx/nginx.conf
ports:
- '8000:8000'
- '4631:4631'

traefik:
command:
Expand Down
6 changes: 1 addition & 5 deletions src/web/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,5 @@ WORKDIR /

COPY --from=dependencies /app/out /var/www/data

COPY --from=dependencies /docusaurus/build /usr/share/nginx/html/

# Add Healthcheck
HEALTHCHECK --interval=30s --timeout=30s --start-period=5s --retries=3 \
CMD curl --fail localhost:4631 || exit 1
COPY --from=dependencies /docusaurus/build /usr/share/nginx/html

0 comments on commit 68f59b4

Please sign in to comment.