From 40cc49f4c821c35758455ad502db96e2e275b6e5 Mon Sep 17 00:00:00 2001 From: Fascinated Date: Tue, 4 Jul 2023 17:14:31 +0100 Subject: [PATCH] maybe fix php now? --- Dockerfile | 3 +++ docker/nginx.conf | 20 ++++++++++---------- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/Dockerfile b/Dockerfile index f0caf2f..58a9ad4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,5 +12,8 @@ COPY ./docker/nginx.conf /etc/nginx/nginx.conf COPY ./upload.php /tmp/upload.php COPY ./docker/start.sh /start.sh +# Start php dependencies +RUN service php8.1-fpm start + # Start server CMD ["bash", "/start.sh"] \ No newline at end of file diff --git a/docker/nginx.conf b/docker/nginx.conf index 80dcec6..6b3fd3a 100644 --- a/docker/nginx.conf +++ b/docker/nginx.conf @@ -23,16 +23,6 @@ http { client_max_body_size 500M; - # TCP optimizations - tcp_nopush on; - tcp_nodelay on; - - # file shit - sendfile on; - - # Keep connections alive for 15 seconds - keepalive_timeout 15; - location ~ \.php$ { try_files $uri =404; @@ -47,6 +37,16 @@ http { location / { expires 7d; + # TCP optimizations + tcp_nopush on; + tcp_nodelay on; + + # file shit + sendfile on; + + # Keep connections alive for 15 seconds + keepalive_timeout 15; + open_file_cache max=1000 inactive=60s; open_file_cache_valid 60s; open_file_cache_min_uses 1;