diff --git a/docker/nginx/dist/conf/tpotweb.conf b/docker/nginx/dist/conf/tpotweb.conf index 24e346ab..67b079a4 100644 --- a/docker/nginx/dist/conf/tpotweb.conf +++ b/docker/nginx/dist/conf/tpotweb.conf @@ -15,12 +15,10 @@ server { root /var/lib/nginx/html; add_header Cache-Control "public, max-age=604800"; - ############################################## ### Remove version number add different header ############################################## server_tokens off; - more_set_headers 'Server: apache'; ############################################## diff --git a/docker/nginx/dist/html/assets/icons/favicon.png b/docker/nginx/dist/html/assets/icons/favicon.png index 0d4b5bef..2b7ef063 100644 Binary files a/docker/nginx/dist/html/assets/icons/favicon.png and b/docker/nginx/dist/html/assets/icons/favicon.png differ diff --git a/docker/nginx/dist/html/assets/js/lists.js b/docker/nginx/dist/html/assets/js/lists.js index d329e43e..34e3becc 100644 --- a/docker/nginx/dist/html/assets/js/lists.js +++ b/docker/nginx/dist/html/assets/js/lists.js @@ -5,7 +5,7 @@ // Print the first List const isLinkAvailable = async (link) => { try { - const response = await fetch(link, { method: 'HEAD', redirect: 'manual' }); + const response = await fetch(link, { method: 'HEAD', mode: 'no-cors' }); if (response.ok) { // The link is available return true; @@ -13,7 +13,7 @@ const isLinkAvailable = async (link) => { // The link is a redirect, follow the redirect and check the final location const newLocation = response.headers.get('Location'); if (newLocation) { - const newResponse = await fetch(newLocation, { method: 'HEAD' }); + const newResponse = await fetch(newLocation, { method: 'HEAD', mode: 'no-cors' }); if (newResponse.ok) { // The final location is available return true; diff --git a/docker/nginx/dist/html/cockpit.html b/docker/nginx/dist/html/cockpit.html new file mode 100644 index 00000000..96c71fac --- /dev/null +++ b/docker/nginx/dist/html/cockpit.html @@ -0,0 +1,13 @@ + + + + + Redirect to Cockpit + + + + + + diff --git a/docker/nginx/dist/html/config.js b/docker/nginx/dist/html/config.js index 3524e7cb..3ec00428 100644 --- a/docker/nginx/dist/html/config.js +++ b/docker/nginx/dist/html/config.js @@ -5,8 +5,6 @@ // │ │ ││││├┤ ││ ┬│ │├┬┘├─┤ │ ││ ││││ // └─┘└─┘┘└┘└ ┴└─┘└─┘┴└─┴ ┴ ┴ ┴└─┘┘└┘ -// Create link for Cockpit redirection (instead of cockpit.html), so we can create links dynamically in assets/js/lists.js -const redirectCockpit = window.location.protocol + '//' + window.location.hostname + ':64294' const CONFIG = { // ┌┐ ┌─┐┌─┐┬┌─┐┌─┐ // ├┴┐├─┤└─┐││ └─┐ @@ -40,7 +38,7 @@ const CONFIG = { }, { name: 'Cockpit', - link: redirectCockpit, + link: '/cockpit.html', }, { name: 'Cyberchef', diff --git a/docker/nginx/dist/html/favicon.ico b/docker/nginx/dist/html/favicon.ico deleted file mode 100644 index 2b7ef063..00000000 Binary files a/docker/nginx/dist/html/favicon.ico and /dev/null differ