Update client/nginx.conf
This commit is contained in:
@@ -2,19 +2,18 @@ server {
|
|||||||
listen 80;
|
listen 80;
|
||||||
server_name _;
|
server_name _;
|
||||||
|
|
||||||
# Racine du site dans le conteneur
|
# ⚠ Ici on pointe directement sur le dossier "browser"
|
||||||
root /usr/share/nginx/html;
|
root /usr/share/nginx/html/browser;
|
||||||
index index.html;
|
index index.html;
|
||||||
|
|
||||||
# === App Angular servie à la racine du conteneur ===
|
# === App Angular (SPA) servie à la racine du conteneur ===
|
||||||
# Traefik enlève déjà /gameovergne, donc ici on est sur "/"
|
# Traefik enlève déjà /gameovergne, donc ici on voit "/"
|
||||||
location / {
|
location / {
|
||||||
# SPA : toutes les routes Angular renvoient index.html
|
|
||||||
try_files $uri $uri/ /index.html;
|
try_files $uri $uri/ /index.html;
|
||||||
}
|
}
|
||||||
|
|
||||||
# === Proxy PrestaShop : /ps/* -> https://shop.gameovergne.fr/api/* ===
|
# === Proxy PrestaShop : /ps/* -> https://shop.gameovergne.fr/api/* ===
|
||||||
# Côté navigateur, l'app appelle /gameovergne/ps/...
|
# Côté navigateur, ton code appelle /gameovergne/ps/...
|
||||||
# Traefik strippe /gameovergne -> Nginx voit /ps/...
|
# Traefik strippe /gameovergne -> Nginx voit /ps/...
|
||||||
location /ps/ {
|
location /ps/ {
|
||||||
proxy_pass https://shop.gameovergne.fr/api/;
|
proxy_pass https://shop.gameovergne.fr/api/;
|
||||||
|
|||||||
Reference in New Issue
Block a user