From d33922ddc101cc10b47626b98e498a7e10bdedbb Mon Sep 17 00:00:00 2001 From: Matej Kubinec Date: Fri, 7 Jun 2024 11:51:19 +0200 Subject: [PATCH] PMM-11231 Use /pmm-ui as path --- build/ansible/roles/nginx/files/conf.d/pmm.conf | 2 +- ui/pmm-dev.conf | 4 ++-- ui/src/router.tsx | 2 +- ui/vite.config.ts | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/build/ansible/roles/nginx/files/conf.d/pmm.conf b/build/ansible/roles/nginx/files/conf.d/pmm.conf index cd922120de..0e20de3981 100644 --- a/build/ansible/roles/nginx/files/conf.d/pmm.conf +++ b/build/ansible/roles/nginx/files/conf.d/pmm.conf @@ -127,7 +127,7 @@ } # PMM UI - location /pmm { + location /pmm-ui { alias /usr/share/pmm-ui; try_files $uri /index.html break; } diff --git a/ui/pmm-dev.conf b/ui/pmm-dev.conf index 021073039d..47a5af63dc 100644 --- a/ui/pmm-dev.conf +++ b/ui/pmm-dev.conf @@ -4,8 +4,8 @@ server { server_name _; # proxy requests during development to vite dev server - location /pmm { - proxy_pass http://host.docker.internal:5173/pmm; + location /pmm-ui { + proxy_pass http://host.docker.internal:5173/pmm-ui; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade"; diff --git a/ui/src/router.tsx b/ui/src/router.tsx index c241ba676c..fdc20d9dff 100644 --- a/ui/src/router.tsx +++ b/ui/src/router.tsx @@ -24,7 +24,7 @@ const router = createBrowserRouter( }, ], { - basename: '/pmm', + basename: '/pmm-ui', } ); diff --git a/ui/vite.config.ts b/ui/vite.config.ts index 1f039062ea..abc1f8aa1f 100644 --- a/ui/vite.config.ts +++ b/ui/vite.config.ts @@ -5,7 +5,7 @@ import { defineConfig } from 'vitest/config'; // https://vitejs.dev/config/ export default defineConfig({ plugins: [tsconfigPaths({ root: '.' }), react()], - base: '/pmm', + base: '/pmm-ui', server: { proxy: { '/v1': {