Commit 3d6e7b3e authored by MikeyMJCO's avatar MikeyMJCO
Browse files

:v2018 branch created - symfony updated to v4.1.6 and working.

parent 31d93eac
server {
root /var/www/civicrm-docs-v2018/web;
# For a development configuration, change "app" to "app_dev" everywhere
# below. Then you'll see the Symfony web debug toolbar when viewing pages.
# Requests for static book files
# - Book slug can't begin with underscore
# - Book slug can't be "admin"
# - Must begin with three distinct path pieces, separated by forward slashes
location ~ ^/(?!_)(?!admin/)[^/]+/[^/]+/[^/]+ {
# - Use a trailing slash for the $uri to treat paths like directories
# - Then, try to find directories that match our request.
# - If we can't find anything, we send the request to the app and let
# it deal with the rest.
try_files $uri/ $uri /app_dev.php$is_args$args;
# requests for Symfony app functionality
location / {
# - Don't use a trailing slash for $uri here. This line is straight from
# the Symfony recommended nginx settings
try_files $uri /app_dev.php$is_args$args;
location ~ ^/app_dev\.php(/|$) {
fastcgi_pass unix:/var/run/php/php7.1-fpm.sock;
fastcgi_split_path_info ^(.+\.php)(/.*)$;
include fastcgi_params;
# When you are using symlinks to link the document root to the
# current version of your application, you should pass the real
# application path instead of the path to the symlink to PHP
# FPM.
# Otherwise, PHP's OPcache may not properly detect changes to
# your PHP files (see
# for more information).
fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
fastcgi_param DOCUMENT_ROOT $realpath_root;
# Prevents URIs that include the front controller. This will 404:
# http://domain.tld/app.php/some-path
# Remove the internal directive to allow URIs like this
# return 404 for all other php files not matching the front controller
# this prevents access to other php files you don't want to be accessible.
location ~ \.php$ {
return 404;
error_log /var/log/nginx/civicrm-docs-error.log;
access_log /var/log/nginx/civicrm-docs-access.log;
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
server {
if ($host = {
return 301 https://$host$request_uri;
} # managed by Certbot
listen 80;
return 404; # managed by Certbot
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment