From fc846225f525ed63ddcc23a8a57a3e3029898584 Mon Sep 17 00:00:00 2001 From: nutra-bot Date: Mon, 5 Jan 2026 13:26:42 +0000 Subject: [PATCH] track nginx for moms-website --- etc/nginx/conf.d/default.conf | 25 ---------- etc/nginx/conf.d/moms-website.conf | 74 +++++++++++++++++++++++++++++ etc/nutra.env | Bin 230 -> 0 bytes 3 files changed, 74 insertions(+), 25 deletions(-) create mode 100644 etc/nginx/conf.d/moms-website.conf delete mode 100644 etc/nutra.env diff --git a/etc/nginx/conf.d/default.conf b/etc/nginx/conf.d/default.conf index 08c5040..b020d12 100644 --- a/etc/nginx/conf.d/default.conf +++ b/etc/nginx/conf.d/default.conf @@ -1,28 +1,3 @@ -server { - listen 80; - server_name 216.218.216.163; - root /var/www/moms-website; - index index.html; - location / { - try_files $uri $uri/ /index.html; - } - location /store { - proxy_pass http://localhost:9000; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection 'upgrade'; - proxy_set_header Host $host; - proxy_cache_bypass $http_upgrade; - } -} -# Redirect all HTTP to HTTPS with no-WWW -server { - listen 80 default_server; - listen [::]:80 default_server; - server_name ~^(?:www\.)?(.*)$; - return 301 https://$1$request_uri; -} - # API server { server_name api-dev.nutra.tk api.dev.nutra.tk; diff --git a/etc/nginx/conf.d/moms-website.conf b/etc/nginx/conf.d/moms-website.conf new file mode 100644 index 0000000..983ef1c --- /dev/null +++ b/etc/nginx/conf.d/moms-website.conf @@ -0,0 +1,74 @@ +# Mom's Earthy Bites Kitchen storefront +server { + server_name earthyenergy.mooo.com; + + root /var/www/moms-website; + index index.html; + + # Allow certbot verification + location /.well-known/acme-challenge/ { + root /var/www/html; + } + + location / { + try_files $uri $uri/ /index.html; + } + + location /store { + proxy_pass http://localhost:9000; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection 'upgrade'; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + proxy_cache_bypass $http_upgrade; + } + + # Proxy to Medusa Auth API (Required for Dashboard login) + location /auth { + proxy_pass http://localhost:9000; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection 'upgrade'; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + proxy_cache_bypass $http_upgrade; + } + + # Proxy to Medusa Admin API (Required for Dashboard login) + location /admin { + proxy_pass http://localhost:9000; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection 'upgrade'; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; + proxy_cache_bypass $http_upgrade; + } + + listen 443 ssl; # managed by Certbot + ssl_certificate /etc/letsencrypt/live/earthyenergy.mooo.com/fullchain.pem; # managed by Certbot + ssl_certificate_key /etc/letsencrypt/live/earthyenergy.mooo.com/privkey.pem; # managed by Certbot + include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot + ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot + +} + +server { + if ($host = earthyenergy.mooo.com) { + return 301 https://$host$request_uri; + } # managed by Certbot + + + listen 80; + server_name earthyenergy.mooo.com; + return 404; # managed by Certbot + + +} \ No newline at end of file diff --git a/etc/nutra.env b/etc/nutra.env deleted file mode 100644 index 8a237c566493279ad7e8c175c0e8beb76b3240ad..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 230 zcmV|+0ECK$>EpOpdZKnSz-Y$Rkg5sqN# zsQ7meXM-fxLYwsx$Y6RGugaKdCU1_sT^&t$fBItqrdPQ__1jYZI<6p-DECAU05ucx za>5B-W+zM-Yb%(7J-oFJoI}?{5_`pgZVV%LlVynDtX15(veB>SNDnt87M+NvF1sPu zgKr^KM^FS&TOnnKGmrW~HL3_D8ZsDhXr22cE(sV|<6D~8KT