using ngx_http_sub_module for injecting CSS
This commit is contained in:
parent
b3522d1662
commit
23e947efff
@ -3,4 +3,5 @@ FROM nginx
|
|||||||
MAINTAINER "Ivan Ermilov <mailto:ivan.s.ermilov@gmail.com>"
|
MAINTAINER "Ivan Ermilov <mailto:ivan.s.ermilov@gmail.com>"
|
||||||
|
|
||||||
COPY default.conf /etc/nginx/conf.d/default.conf
|
COPY default.conf /etc/nginx/conf.d/default.conf
|
||||||
COPY custom.html /data/bde-css/custom.html
|
COPY materialize.min.css /data/bde-css/materialize.min.css
|
||||||
|
COPY bde-hadoop.css /data/bde-css/bde-hadoop.css
|
||||||
|
File diff suppressed because one or more lines are too long
@ -3,22 +3,33 @@ server {
|
|||||||
server_name localhost;
|
server_name localhost;
|
||||||
|
|
||||||
root /data;
|
root /data;
|
||||||
add_after_body /bde-css/custom.html;
|
gzip on;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
proxy_http_version 1.1;
|
proxy_pass http://127.0.0.1:8000;
|
||||||
proxy_set_header Upgrade $http_upgrade;
|
proxy_set_header Accept-Encoding "";
|
||||||
proxy_set_header Connection 'upgrade';
|
|
||||||
proxy_cache_bypass $http_upgrade;
|
|
||||||
proxy_set_header Host $host;
|
|
||||||
proxy_set_header X-Real-IP $remote_addr;
|
|
||||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
||||||
proxy_set_header X-NginX-Proxy true;
|
|
||||||
proxy_redirect off;
|
|
||||||
proxy_pass http://namenode:50070;
|
|
||||||
#rewrite ^/sparql/(.*)$ /$1 break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
location /bde-css/ {
|
location /bde-css/ {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 127.0.0.1:8000;
|
||||||
|
location / {
|
||||||
|
proxy_pass http://127.0.0.1:8001;
|
||||||
|
sub_filter '</head>' '<link rel="stylesheet" type="text/css" href="/bde-css/materialize.min.css">
|
||||||
|
<link rel="stylesheet" type="text/css" href="/bde-css/bde-hadoop.css"></head>';
|
||||||
|
sub_filter_once on;
|
||||||
|
proxy_set_header Accept-Encoding "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 127.0.0.1:8001;
|
||||||
|
gunzip on;
|
||||||
|
location / {
|
||||||
|
proxy_pass http://namenode:50070;
|
||||||
|
proxy_set_header Accept-Encoding gzip;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user