Skip to content

Commit

Permalink
add nginx to container
Browse files Browse the repository at this point in the history
  • Loading branch information
dsschult committed Nov 29, 2024
1 parent 51261dc commit 57892bb
Show file tree
Hide file tree
Showing 2 changed files with 68 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,17 @@ ARG VERSION=latest

FROM ghcr.io/indico/indico:$VERSION

USER root

RUN set -ex && \
apt-get update && \
apt-get -y install nginx && \
apt-get clean

RUN chown indico:indico /var/lib/nginx

COPY nginx.conf /etc/nginx/nginx.conf

# all the installations etc can be done using the unprivileged indico user
USER indico

Expand Down
57 changes: 57 additions & 0 deletions nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# user indico;
daemon off;
worker_processes 1;
pid /tmp/nginx.pid;
error_log stderr info;
include /etc/nginx/modules-enabled/*.conf;

events {
worker_connections 1024;
# multi_accept on;
}

http {

##
# Basic Settings
##

sendfile on;
tcp_nopush on;
types_hash_max_size 2048;

include /etc/nginx/mime.types;
default_type application/octet-stream;

##
# SSL Settings
##

ssl_protocols TLSv1.1 TLSv1.2 TLSv1.3;
ssl_prefer_server_ciphers on;

##
# Logging Settings
##

access_log /dev/stdout combined;

##
# Gzip Settings
##

gzip on;

# gzip_vary on;
# gzip_proxied any;
# gzip_comp_level 6;
# gzip_buffers 16 8k;
# gzip_http_version 1.1;
# gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;

##
# Virtual Host Configs
##

include /etc/nginx/conf.d/*.conf;
}

0 comments on commit 57892bb

Please sign in to comment.