Skip to content

Commit

Permalink
Add nginx.conf for Docker container
Browse files Browse the repository at this point in the history
  • Loading branch information
Konstantin Nazarov committed Aug 2, 2016
1 parent d220f33 commit 554061c
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 0 deletions.
32 changes: 32 additions & 0 deletions nginx.conf
@@ -0,0 +1,32 @@
user nginx;
worker_processes 1;

error_log /var/log/nginx/error.log warn;
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;
}

20 changes: 20 additions & 0 deletions nginx.vh.default.conf
@@ -0,0 +1,20 @@
upstream backend {
# Tarantool hosts
server 127.0.0.1:9999;
}

server {
listen 80;
server_name localhost;

location /tnt_rest {
# REST mode on
tnt_http_rest_methods get post put delete; # or all

# Pass http headers and uri
tnt_pass_http_request on;

# Module on
tnt_pass backend;
}
}

0 comments on commit 554061c

Please sign in to comment.