This commit is contained in:
William 2022-12-29 03:05:39 +00:00
parent 75edb6984f
commit 808649de7f
4 changed files with 15 additions and 4 deletions

View File

@ -12,8 +12,12 @@ RUN mkdir /www && \
chown -R www:www /var/lib/nginx && \
chown -R www:www /www
COPY nginx.conf /etc/nginx/nginx.conf
COPY ./docker/nginx.conf /etc/nginx/nginx.conf
COPY ../ /www
COPY ./ /www
CMD ["nginx && php-fpm81 && sleep infinity"]
COPY ./docker/run.sh /opt/run.sh
RUN chmod +x /opt/run.sh
CMD ["/opt/run.sh"]

View File

@ -1 +1,3 @@
# Docker install
docker build --no-cache -f ./docker/Dockerfile --tag willy-club-website

View File

@ -25,6 +25,9 @@ http {
location = /50x.html {
root /var/lib/nginx/html;
}
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location ~ \.php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;

2
docker/run.sh Normal file
View File

@ -0,0 +1,2 @@
#!/bin/sh
nginx && php-fpm81 && read var