This commit is contained in:
root
2020-05-09 00:19:38 -04:00
parent e4b87cb50b
commit fc2ea8f76b
19 changed files with 182 additions and 18 deletions

View File

@@ -6,7 +6,7 @@ rewrite ^/$ http://icinga.keiran.us/icingaweb2 permanent;
location ~ ^/icingaweb2/index\.php(.*)$ {
# fastcgi_pass 127.0.0.1:9000;
fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;
fastcgi_pass unix:/var/run/php/php7.3-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME /usr/share/icingaweb2/public/index.php;
@@ -23,11 +23,32 @@ rewrite ^/$ http://icinga.keiran.us/icingaweb2 permanent;
location ~ ^/ccfc/$ {
auth_basic "Login";
auth_basic_user_file /var/www/htpasswd_ccfc;
fastcgi_pass unix://var/run/php/php7.0-fpm.sock;
fastcgi_pass unix://var/run/php/php7.3-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME /var/www/ccfc/index.php;
fastcgi_param REMOTE_USER $remote_user;
}
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/icinga.keiran.us/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/icinga.keiran.us/privkey.pem; # 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 = icinga.keiran.us) {
return 301 https://$host$request_uri;
} # managed by Certbot
server_name icinga.keiran.us;
listen 80;
return 404; # managed by Certbot
}

View File

@@ -4,6 +4,9 @@ icinga_packages:
- pkgs:
- icinga2
- icingaweb2
- icinga2-ido-mysql
- certbot
- python-certbot-nginx
apache2:
service.dead:
@@ -15,7 +18,7 @@ apache2:
icingaweb2_vhost:
file.managed:
- name: /etc/nginx/sites-enabled/icingaweb2
- name: /etc/nginx/sites-available/icingaweb2
- source: 'salt://icinga2/files/icingaweb2.jinja'
- template: jinja
- user: root