Skip to content
Snippets Groups Projects
Commit 1eb58cd9 authored by Kawtar Laariche's avatar Kawtar Laariche
Browse files

feat: support hosting Angular frontend under /v2 path

parent 0cee4c19
No related branches found
No related tags found
No related merge requests found
...@@ -14,7 +14,7 @@ RUN npm install ...@@ -14,7 +14,7 @@ RUN npm install
COPY . . COPY . .
# Build the Angular app # Build the Angular app
RUN npm run ng build --configuration=prod RUN npx ng build --base-href=/v2/ --configuration=prod
#RUN npm run ng -- build --configuration=dev02 #RUN npm run ng -- build --configuration=dev02
......
server { server {
listen 80; listen 80;
server_name localhost; server_name localhost;
root /usr/share/nginx/html; root /usr/share/nginx/html;
index index.html;
location / { location /v2/ {
# Angular routing fallback alias /usr/share/nginx/html/;
try_files $uri /index.html; index index.html;
try_files $uri $uri/ /index.html;
} }
error_page 404 /index.html; error_page 404 /v2/index.html;
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment