From 2a1397fef27cd99feed9f58a196a985fcd919085 Mon Sep 17 00:00:00 2001 From: Jamon Camisso Date: Sun, 27 Aug 2023 10:38:09 -0400 Subject: [PATCH] Add nginx rewrite for root /vulnerabilities/ url Signed-off-by: Jamon Camisso --- nginx.conf | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/nginx.conf b/nginx.conf index 5e28cf9f24..71b4394fd8 100644 --- a/nginx.conf +++ b/nginx.conf @@ -59,6 +59,13 @@ http { try_files $uri $uri/index.html =404; } + # serve the vuln-comparison page for /vulnerabilities page without a vuln id + # captures /vulnerabilities /vulnerabilities/ and /vulnerabilities/index.html + location ~ ^/vulnerabilities(\/|\/index.html)?$ { + rewrite ^ /chainguard/chainguard-images/vuln-comparison/index.html; + } + + # all vulnerabilities with an ID get rendered by this page using javascript location ~ ^/vulnerabilities/ { rewrite ^ /vulnerabilities/index.html break; }