I have nginx installed on my Centos 7 box and would like to forward calls to my kibana installation on port 5601. Kibana is up and running and am able to browse to it by by appending the port to the url in the browser.
My nginx.conf file is as follows
user nginx;
worker_processes auto;
error_log /var/log/nginx/error.log;
pid /run/nginx.pid;
events {
worker_connections 1024;
}
http {
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;
tcp_nodelay on;
keepalive_timeout 65;
types_hash_max_size 2048;
include /etc/nginx/mime.types;
default_type application/octet-stream;
# Load modular configuration files from the /etc/nginx/conf.d directory.
# See http://nginx.org/en/docs/ngx_core_module.html#include
# for more information.
include /etc/nginx/conf.d/*.conf;
}
in the conf.d directory I have placed a file called default.conf that looks like:
server {
listen 80;
server_name 192.168.33.36;
#auth_basic "Restricted Access";
#auth_basic_user_file /etc/nginx/htpasswd.users;
location / {
proxy_pass http://192.168.33.36:5601;
#proxy_http_version 1.1;
#proxy_set_header Upgrade $http_upgrade;
#proxy_set_header Connection 'upgrade';
#proxy_set_header Host $host;
#proxy_cache_bypass $http_upgrade;
}
}
I new to nginx so im sure im doing something stupid but I have spent hours trying to figure it out. Anyone know whats wrong?
Nginix is running becuase when i browse to port 80 i get the default nginx web page displayed but it doesn forward to port 5601