mirror of
https://github.com/portainer/portainer.git
synced 2025-08-05 22:05:23 +02:00
fix(security): add initial support for HSTS and CSP BE-11311 (#47)
Some checks failed
Label Conflicts / triage (push) Has been cancelled
Some checks failed
Label Conflicts / triage (push) Has been cancelled
This commit is contained in:
parent
ac293cda1c
commit
3114d4b5c5
5 changed files with 37 additions and 23 deletions
|
@ -10,19 +10,6 @@
|
|||
<meta http-equiv="pragma" content="no-cache" />
|
||||
<meta name="robots" content="noindex" />
|
||||
<base id="base" />
|
||||
<script>
|
||||
// http://localhost:49000 is a docker extension specific url (see /build/docker-extension/docker-compose.yml)
|
||||
if (window.origin == 'http://localhost:49000') {
|
||||
// we are loading the app from a local file as in docker extension
|
||||
document.getElementById('base').href = 'http://localhost:49000/';
|
||||
|
||||
window.ddExtension = true;
|
||||
} else {
|
||||
var path = window.location.pathname.replace(/^\/+|\/+$/g, '');
|
||||
var basePath = path ? '/' + path + '/' : '/';
|
||||
document.getElementById('base').href = basePath;
|
||||
}
|
||||
</script>
|
||||
|
||||
<!-- HTML5 shim, for IE6-8 support of HTML5 elements -->
|
||||
<!--[if lt IE 9]>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue