Commit a66b822f authored by Daniel Suarez Souto's avatar Daniel Suarez Souto
Browse files

proxy removed

parent 6f601f3a
Pipeline #1081 passed with stages
in 34 seconds
......@@ -3,7 +3,9 @@ version: '3'
services:
sefarad:
build: .
image: trivalent/dashboard-trivalent
image: registry.cluster.gsi.dit.upm.es/trivalent/dashboard-trivalent
ports:
- 8080:8080
volumes:
- .:/usr/src/app
environment:
......@@ -12,20 +14,6 @@ services:
networks:
- sefarad-network
proxy:
build:
context: nginx/.
args:
- USER_DASHBOARD=${USER_DASHBOARD}
- PWD_DASHBOARD=${PWD_DASHBOARD}
image: trivalent/nginx-proxy-dashboard
ports:
- 8080:8080
networks:
- sefarad-network
networks:
sefarad-network:
driver: bridge
\ No newline at end of file
FROM nginx:alpine
ARG USER_DASHBOARD
ARG PWD_DASHBOARD
RUN apk add --no-cache openssl
COPY nginx.conf /etc/nginx/nginx.conf
RUN sh -c "echo -n '${USER_DASHBOARD}:' >> /etc/nginx/htpasswd"
RUN sh -c "openssl passwd ${PWD_DASHBOARD} >> /etc/nginx/htpasswd"
worker_processes 1;
events { worker_connections 1024; }
http {
sendfile on;
upstream docker-sefarad {
server sefarad:8080;
}
server {
listen 8080;
location / {
auth_basic "Restricted";
auth_basic_user_file /etc/nginx/htpasswd;
proxy_pass http://docker-sefarad;
proxy_redirect off;
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-Forwarded-Host $server_name;
}
}
}
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment