-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
49 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
web: vendor/bin/heroku-php-nginx -C nginx_app.conf public/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
index index.php index.html; | ||
charset UTF-8; | ||
default_type text/html; | ||
|
||
gzip on; | ||
gzip_disable "msie6"; | ||
|
||
gzip_vary on; | ||
gzip_proxied any; | ||
gzip_comp_level 6; | ||
gzip_buffers 16 8k; | ||
gzip_min_length 10; | ||
gzip_http_version 1.1; | ||
gzip_types application/json; | ||
|
||
client_max_body_size 10M; | ||
|
||
location / { | ||
# try to serve file directly, fallback to rewrite | ||
try_files $uri @rewriteapp; | ||
} | ||
|
||
location @rewriteapp { | ||
# rewrite all to app.php | ||
rewrite ^(.*)$ /v1/index.php/?req=$1 last; | ||
} | ||
|
||
location /api { | ||
rewrite ^/api\/v1\/processes[\/]?$ /v1/processes.php; | ||
rewrite ^/api\/v1\/processes\/([0-9]+)[\/]?$ /v1/process.php?id=$1; | ||
rewrite ^/api\/v1\/processes\/([0-9]+)\/tags[\/]?$ /v1/process_tags.php?id=$1; | ||
rewrite ^/api\/v1\/processes\/([0-9]+)\/timeline[\/]?$ /v1/process_timeline.php?id=$1; | ||
rewrite ^/api\/v1\/tags\/([0-9]+)[\/]?$ /v1/tag.php?id=$1; | ||
rewrite ^/api\/v1\/tags\/([0-9]+)\/records[\/]?$ /v1/tag_records.php?id=$1; | ||
} | ||
|
||
location = /favicon.ico { | ||
log_not_found off; | ||
access_log off; | ||
} | ||
|
||
location ~* \.(xml|ogg|ogv|svg|svgz|eot|otf|woff|mp4|ttf|css|rss|atom|js|jpg|jpeg|gif|png|ico|zip|tgz|gz|rar|bz2|doc|xls|exe|ppt|tar|mid|midi|wav|bmp|rtf)$ { | ||
try_files $uri =404; | ||
expires max; | ||
add_header Pragma "public"; | ||
add_header Cache-Control "public, must-revalidate, proxy-revalidate"; | ||
access_log off; | ||
} |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.