summaryrefslogtreecommitdiff
path: root/etc/nginx/crm.conf.sample
diff options
context:
space:
mode:
authorYaco <franco@reevo.org>2020-06-04 11:01:00 -0300
committerYaco <franco@reevo.org>2020-06-04 11:01:00 -0300
commitfc7369835258467bf97eb64f184b93691f9a9fd5 (patch)
treedaabd60089d2dd76d9f5fb416b005fbe159c799d /etc/nginx/crm.conf.sample
first commit
Diffstat (limited to 'etc/nginx/crm.conf.sample')
-rwxr-xr-xetc/nginx/crm.conf.sample44
1 files changed, 44 insertions, 0 deletions
diff --git a/etc/nginx/crm.conf.sample b/etc/nginx/crm.conf.sample
new file mode 100755
index 00000000..27754a01
--- /dev/null
+++ b/etc/nginx/crm.conf.sample
@@ -0,0 +1,44 @@
+# ----
+# Copyright (C) 2013-2020 - Reevo (http://reevo.org)
+# License: Affero GPL version 3 - http://www.gnu.org/licenses/agpl.html
+# ES: Este archivos es parte de: reevo-2020 (http://git.reevo.org/reevo/reevo-2020)
+# EN: This file is part of: reevo-2020 (http://git.reevo.org/reevo/reevo-2020)
+# ----
+
+server {
+ server_name crm.example.org example.org;
+ root /srv/reevo-2020/www/crm;
+
+ access_log /srv/reevo-2020/log/crm/nginx.access.log;
+ error_log /srv/reevo-2020/log/crm/nginx.error.log warn;
+
+ index index.html index.htm index.php;
+
+ location ~ \.php$ {
+ # Sitio offline
+ if ($maintenance) { return 503; }
+
+ # Bloquea bots
+ if ($limit_bots) { add_header X-Robots-Tag "noindex, nofollow, nosnippet, noarchive"; }
+
+ include /etc/nginx/fastcgi_params;
+ fastcgi_pass unix:/srv/reevo-2020/run/crm.socket;
+ fastcgi_index index.php;
+ fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
+ }
+
+ add_header Access-Control-Allow-Origin *;
+ rewrite /wp-admin$ $scheme://$host$uri/ permanent;
+ try_files $uri $uri/ /index.php?$args;
+
+ error_page 503 @maintenance;
+ location @maintenance {
+ rewrite ^(.*)$ /errors/503/index.html break;
+ }
+
+ location /wp-content/plugins/files/civicrm/ {
+ deny all;
+ return 404;
+ }
+
+}