-
Notifications
You must be signed in to change notification settings - Fork 2
/
nginx.conf
60 lines (56 loc) · 1.82 KB
/
nginx.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
server {
listen 8080;
#listen [::]:8080;
server_name localhost;
location / {
sub_filter </head>
'</head>
<div id="devbar" >
<span class="title" >
Dev Bar
</span>
<label for="remoteuser">User: </label>
<select name="remoteuser" id="setremoteuser" >
<option value="superadmin">superadmin</option>
<option value="eidc-editor">eidc-editor</option>
<option value="eidc-publisher">eidc-publisher</option>
<option value="infrastructure-editor">infrastructure-editor</option>
<option value="infrastructure-publisher">infrastructure-publisher</option>
<option value="ukceh-editor">ukceh-editor</option>
<option value="ukceh-publisher">ukceh-publisher</option>
<option value="ukeof-publisher">ukeof-publisher</option>
<option value="unprivileged" selected>unprivileged</option>
= </select>
<style>
#devbar {
padding: 1rem;
background-color: #d8dee9;
color: #4c566a;
height: 5rem;
border-bottom: #0000002e solid 2px;
.title {
padding: 10px;
margin-right: 1rem;
font-weight: bold;
border-right: #4c566a2e solid 2px;
}
}
#search {
.results {
margin-bottom: 5rem;
}
}
</style>
<script>
document.querySelector("#setremoteuser").addEventListener("change", e => {
document.cookie = "remoteuser="+e.target.value+"; path=/";
location.reload();
});
document.querySelector("#setremoteuser").value = "$cookie_remoteuser";
</script>
</div>';
proxy_set_header Remote-User $cookie_remoteuser;
proxy_set_header Host localhost:8080;
proxy_pass http://web:8080/;
}
}