Skip to content

Commit 14ef0bb

Browse files
author
stodaro
committed
change webapp path
1 parent 8257350 commit 14ef0bb

File tree

2 files changed

+19
-23
lines changed

2 files changed

+19
-23
lines changed

laravel5/Dockerfile

+3-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# docker build -f Dockerfile -t qwince/laravel5 .
22
FROM ubuntu:xenial
33
MAINTAINER Qwince <[email protected]>
4+
45
# Install packages
56
RUN apt-get update -y && apt-get -y upgrade && DEBIAN_FRONTEND=noninteractive apt-get -y install ca-certificates supervisor git curl wget nano --no-install-recommends
67
RUN DEBIAN_FRONTEND=noninteractive apt-get -y install nginx php7.0-mcrypt php7.0-mbstring php7.0-gd nginx php7.0-fpm php7.0-cli php7.0-curl php7.0-mysql --no-install-recommends
@@ -10,18 +11,15 @@ RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
1011
RUN curl -sS https://getcomposer.org/installer | php
1112
RUN mv composer.phar /usr/local/bin/composer
1213

13-
1414
# Volume
15-
VOLUME /var/www
15+
VOLUME /var/www/webapp
1616

1717
ADD webapp/ /var/www/webapp
1818

1919
RUN chown -R www-data.www-data /var/www/*
20-
21-
RUN chmod 755 -R /var/www/webapp/app/storage
20+
RUN chmod 755 -R /var/www/webapp/storage
2221

2322
EXPOSE 80
24-
EXPOSE 443
2523

2624
COPY run_install_laravel.sh /usr/local/bin/run_install_laravel
2725

laravel5/nginx.conf

+16-18
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# http://chilion.nl/setup-a-new-webserver-with-ubuntu-nginx-mariadb-composer-and-git/
1+
22
server {
33
listen 80 default_server;
44

@@ -9,25 +9,23 @@ server {
99
try_files $uri $uri/ /index.php?$query_string;
1010
}
1111

12+
sendfile off;
1213

13-
sendfile off;
14-
15-
client_max_body_size 200m;
16-
17-
location ~ \.php$ {
18-
fastcgi_split_path_info ^(.+\.php)(/.+)$;
19-
fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
20-
fastcgi_index index.php;
21-
include fastcgi_params;
22-
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
23-
fastcgi_intercept_errors off;
14+
client_max_body_size 200m;
2415

25-
fastcgi_buffer_size 16k;
26-
fastcgi_buffers 4 16k;
27-
}
16+
location ~ \.php$ {
17+
fastcgi_split_path_info ^(.+\.php)(/.+)$;
18+
fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
19+
fastcgi_index index.php;
20+
include fastcgi_params;
21+
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
22+
fastcgi_intercept_errors off;
2823

29-
location ~ /\.ht {
30-
deny all;
31-
}
24+
fastcgi_buffer_size 16k;
25+
fastcgi_buffers 4 16k;
26+
}
3227

28+
location ~ /\.ht {
29+
deny all;
30+
}
3331
}

0 commit comments

Comments
 (0)