mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-17 22:36:01 +00:00
#228 use nginx as proxy
This commit is contained in:
3
test/nginx/Dockerfile
Normal file
3
test/nginx/Dockerfile
Normal file
@@ -0,0 +1,3 @@
|
||||
FROM nginx
|
||||
|
||||
COPY nginx.conf /etc/nginx/nginx.conf
|
||||
44
test/nginx/nginx.conf
Normal file
44
test/nginx/nginx.conf
Normal file
@@ -0,0 +1,44 @@
|
||||
user nginx;
|
||||
worker_processes auto;
|
||||
|
||||
error_log /var/log/nginx/error.log notice;
|
||||
pid /var/run/nginx.pid;
|
||||
|
||||
|
||||
events {
|
||||
worker_connections 1024;
|
||||
}
|
||||
|
||||
|
||||
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;
|
||||
|
||||
server {
|
||||
# listen 80;
|
||||
|
||||
# return 302 https://dbgate.org;
|
||||
|
||||
location /dbgate {
|
||||
proxy_pass http://dbgate:3000;
|
||||
|
||||
# proxy_http_version 1.1;
|
||||
# proxy_set_header Connection "";
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user