Describe how greptweet is run in a Dockerfile

This commit is contained in:
EC2 Default User
2014-10-15 10:35:01 +00:00
parent ab8aa55edd
commit 9393107859
5 changed files with 42 additions and 9 deletions

View File

@@ -1,18 +1,20 @@
# sudo systemctl start php-fpm
# sudo systemctl start nginx
# Tested with Nginx 1.6 on Archlinux
daemon off;
worker_processes 1;
events {
worker_connections 1024;
}
http {
include mime.types;
sendfile on;
include mime.types;
sendfile on;
gzip on;
gzip_vary on;
gzip_types application/x-javascript text/css application/javascript text/html application/json;
server {
server_name greptweet;
root /srv/www/greptweet;
server_name greptweet.com;
root /srv/http;
charset utf-8;
access_log /var/log/nginx/greptweet.access.log;
error_log /var/log/nginx/greptweet.error.log;
@@ -22,11 +24,15 @@ http {
rewrite ^/f/(.*)$ /create.php?id=$1 last;
}
location ~ \.txt$ {
location ~ \.(svg|txt)$ {
gzip_static always;
gunzip on;
}
location ~* \.(svg|css|woff|js)$ {
expires 7d;
}
location ~ \.php$ {
try_files $uri = 404;
fastcgi_pass unix:/run/php-fpm/php-fpm.sock;