Skip to content

Commit

Permalink
Merge pull request #130 from ho-nl/feature/graphcommerce-frontend-ngi…
Browse files Browse the repository at this point in the history
…nx-conf

Support separate frontend application reverse proxying through nginx
  • Loading branch information
hnsr authored Nov 21, 2023
2 parents aac05f4 + 8f8966b commit c65eba3
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
4 changes: 4 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@
[
".gitignore",
"var/.esdata/.gitignore"
],
[
"nginx/conf.d/frontend.conf",
"nginx-frontend.conf"
]
],
"chmod": [
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ services:


# phplogs: tail -f /usr/local/var/log/php*
# Uncomment variables MAGE_RUN_TYPE and MAGE_RUN_CODE to allow multistore setup
nginx:
image: nginx:alpine
volumes:
- ./vendor/reach-digital/docker-devbox/nginx/conf.d/default.conf:/etc/nginx/conf.d/default.template:ro
- ./vendor/reach-digital/docker-devbox/nginx/conf.d/default-map.conf:/etc/nginx/conf.d/default-map.conf:ro
- ./nginx-frontend.conf:/etc/nginx/conf.d/frontend.conf:ro
- ./vendor/reach-digital/docker-devbox/nginx/nginx.conf:/etc/nginx/nginx.conf:ro
- nginx-mount:/var/www/data
environment:
Expand Down
13 changes: 13 additions & 0 deletions nginx/conf.d/frontend.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@

# If you are running a seperate frontend application on the host (i.e. a node app running on port 3000), and want to
# enable a multi-store setup, each with it's own domain name, you can define them like below:

#server {
# listen 80;
# server_name storefront-a.localhost.reachdigital.io;
# server_name storefront-b.localhost.reachdigital.io;
#
# location / {
# proxy_pass http://host.docker.internal:3000;
# }
#}

0 comments on commit c65eba3

Please sign in to comment.