OCSInventory-Docker-Image/nightly/nginx/conf/ocsinventory.conf.template
2022-04-19 11:38:23 +02:00

48 lines
1.8 KiB
Plaintext

##
# You should look at the following URL's in order to grasp a solid understanding
# of Nginx configuration files in order to fully unleash the power of Nginx.
# https://www.nginx.com/resources/wiki/start/
# https://www.nginx.com/resources/wiki/start/topics/tutorials/config_pitfalls/
# https://wiki.debian.org/Nginx/DirectoryStructure
#
# In most cases, administrators will remove this file from sites-enabled/ and
# leave it as reference inside of sites-available where it will continue to be
# updated by the nginx packaging team.
#
# This file will automatically load configuration files provided by other
# applications, such as Drupal or Wordpress. These applications will be made
# available underneath a path with that package name, such as /drupal8.
#
# Please see /usr/share/doc/nginx-doc/examples/ for more detailed examples.
##
# OCS server configuration
#
server {
listen ${LISTEN_PORT} ${PORT_TYPE} default_server;
ssl_certificate /etc/nginx/certs/${SSL_CERT};
ssl_certificate_key /etc/nginx/certs/${SSL_KEY};
location / {
proxy_redirect off;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Frame-Options SAMEORIGIN;
proxy_pass http://ocsapplication;
}
location /ocsapi {
auth_basic "OCS Api area";
auth_basic_user_file /etc/nginx/auth/${API_AUTH_FILE};
}
location /download {
proxy_read_timeout ${READ_TIMEOUT};
proxy_connect_timeout ${CONNECT_TIMEOUT};
proxy_send_timeout ${SEND_TIMEOUT};
client_max_body_size ${MAX_BODY_SIZE};
}
}