1
2
mirror of https://github.com/vimagick/dockerfiles synced 2024-06-25 16:28:40 +00:00
This commit is contained in:
kev 2015-09-18 18:39:27 +08:00
parent b89bad9689
commit a7ca7ef2e3
2 changed files with 14 additions and 15 deletions

@ -24,6 +24,7 @@ RUN apk add -U ca-certificates \
&& cd upload \
&& php composer.phar self-update \
&& php composer.phar install \
&& chown -R nobody:nobody public \
&& cd config/autoload \
&& cp database.local.php.dist database.local.php \
&& cp delivery.local.php.dist delivery.local.php \
@ -31,7 +32,6 @@ RUN apk add -U ca-certificates \
&& cp rtb.config.local.php.dist rtb.config.local.php \
&& sed -i -e "s/'pass' => ''/'pass' => 'root'/" \
-e "s/'host' => 'localhost'/'host' => 'mysql'/" database.local.php \
&& chown -R nobody:nobody . \
&& apk del git \
&& rm -rf /var/cache/apk/*

@ -1,3 +1,4 @@
user nobody;
worker_processes 4;
events {
@ -13,14 +14,12 @@ http {
server {
listen 80;
server_name _;
root /var/www/html/upload/public;
try_files $uri @php_index;
root /var/www/html/upload/public/;
index index.php;
location ~ \.php$ {
location @php_index {
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param REDIRECT_STATUS 200;
fastcgi_param SCRIPT_FILENAME $document_root/index.php;
fastcgi_pass 127.0.0.1:9000;
}
}