custom image
This commit is contained in:
parent
2cd272215d
commit
40d013df56
5 changed files with 53 additions and 4 deletions
4
custom/reverseproxy/Dockerfile
Normal file
4
custom/reverseproxy/Dockerfile
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
FROM nginxproxy/nginx-proxy:latest
|
||||||
|
|
||||||
|
COPY config/vhost.d/* /etc/nginx/vhost.d/
|
||||||
|
COPY config/nginx.conf /etc/nginx/nginx.conf
|
34
custom/reverseproxy/config/nginx.conf
Normal file
34
custom/reverseproxy/config/nginx.conf
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
# default config
|
||||||
|
user nginx;
|
||||||
|
worker_processes auto;
|
||||||
|
|
||||||
|
error_log /var/log/nginx/error.log notice;
|
||||||
|
pid /var/run/nginx.pid;
|
||||||
|
|
||||||
|
|
||||||
|
events {
|
||||||
|
worker_connections 10240;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
http {
|
||||||
|
include /etc/nginx/mime.types;
|
||||||
|
default_type application/octet-stream;
|
||||||
|
|
||||||
|
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
||||||
|
'$status $body_bytes_sent "$http_referer" '
|
||||||
|
'"$http_user_agent" "$http_x_forwarded_for"';
|
||||||
|
|
||||||
|
access_log /var/log/nginx/access.log main;
|
||||||
|
|
||||||
|
sendfile on;
|
||||||
|
#tcp_nopush on;
|
||||||
|
|
||||||
|
keepalive_timeout 65;
|
||||||
|
|
||||||
|
#gzip on;
|
||||||
|
|
||||||
|
include /etc/nginx/conf.d/*.conf;
|
||||||
|
}
|
||||||
|
|
||||||
|
daemon off;
|
10
custom/reverseproxy/config/vhost.d/default
Normal file
10
custom/reverseproxy/config/vhost.d/default
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
## Start of configuration add by letsencrypt container
|
||||||
|
location ^~ /.well-known/acme-challenge/ {
|
||||||
|
auth_basic off;
|
||||||
|
auth_request off;
|
||||||
|
allow all;
|
||||||
|
root /usr/share/nginx/html;
|
||||||
|
try_files $uri =404;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
## End of configuration add by letsencrypt container
|
3
custom/reverseproxy/config/vhost.d/faulty.nl
Normal file
3
custom/reverseproxy/config/vhost.d/faulty.nl
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
location /nginx {
|
||||||
|
return 200 "Nginx is running!";
|
||||||
|
}
|
|
@ -7,18 +7,16 @@ networks:
|
||||||
|
|
||||||
services:
|
services:
|
||||||
proxy:
|
proxy:
|
||||||
|
build:
|
||||||
|
context:
|
||||||
container_name: proxy
|
container_name: proxy
|
||||||
restart: always
|
restart: always
|
||||||
image: nginxproxy/nginx-proxy:latest
|
|
||||||
privileged: true
|
privileged: true
|
||||||
ports:
|
ports:
|
||||||
- 80:80
|
- 80:80
|
||||||
- 443:443
|
- 443:443
|
||||||
volumes:
|
volumes:
|
||||||
- /srv/.webcerts:/etc/nginx/certs:rw
|
- /srv/.webcerts:/etc/nginx/certs:rw
|
||||||
- /srv/proxy/other/vhost.d:/etc/nginx/vhost.d
|
|
||||||
- /srv/proxy/data/html:/usr/share/nginx/html
|
|
||||||
- /srv/proxy/config/nginx.conf:/etc/nginx/nginx.conf
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock
|
- /var/run/docker.sock:/tmp/docker.sock
|
||||||
labels:
|
labels:
|
||||||
- com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy=true
|
- com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy=true
|
||||||
|
|
Reference in a new issue