first attempt to ansibleize piwik httpd config
Signed-off-by: Ricky Elrod <codeblock@fedoraproject.org>
This commit is contained in:
parent
38c200766b
commit
ad066cf408
2 changed files with 49 additions and 1 deletions
25
roles/piwik/files/piwik-httpd.conf
Normal file
25
roles/piwik/files/piwik-httpd.conf
Normal file
|
@ -0,0 +1,25 @@
|
|||
<Directory /srv/piwik>
|
||||
Require all granted
|
||||
</Directory>
|
||||
|
||||
<VirtualHost *:80>
|
||||
ServerName piwik.fedorainfracloud.org
|
||||
Redirect permanent / https://piwik.fedorainfracloud.org/piwik
|
||||
</VirtualHost>
|
||||
|
||||
<VirtualHost *:443>
|
||||
ServerName piwik.fedorainfracloud.org
|
||||
|
||||
SSLEngine on
|
||||
SSLProtocol all -SSLv2 -SSLv3
|
||||
# Use secure TLSv1.1 and TLSv1.2 ciphers
|
||||
Header always add Strict-Transport-Security "max-age=15768000; includeSubDomains; preload"
|
||||
|
||||
SSLCertificateFile /etc/pki/tls/certs/piwik.fedorainfracloud.org.cert
|
||||
SSLCertificateChainFile /etc/pki/tls/certs/piwik.fedorainfracloud.org.intermediate.cert
|
||||
SSLCertificateKeyFile /etc/pki/tls/certs/piwik.fedorainfracloud.org.key
|
||||
|
||||
Alias /piwik /srv/piwik
|
||||
|
||||
Redirect / /piwik
|
||||
</VirtualHost>
|
|
@ -5,4 +5,27 @@
|
|||
- packages
|
||||
- piwik
|
||||
|
||||
#- name: set up http configs for piwik
|
||||
- name: set up http configs for piwik
|
||||
template: src={{ item }} dest=/etc/httpd/conf.d/{{ item }}
|
||||
owner=root group=root mode=0644
|
||||
with_items:
|
||||
- piwik-httpd.conf
|
||||
tags:
|
||||
- files
|
||||
- config
|
||||
- piwik
|
||||
notify:
|
||||
- restart apache
|
||||
|
||||
- name: Install the SSL cert so that we can use https
|
||||
copy: >
|
||||
src={{ private}}/files/httpd/{{ item }} dest=/etc/pki/tls/certs/{{ item }}
|
||||
owner=root group=root mode=0600
|
||||
notify: restart stunnel
|
||||
with_items:
|
||||
- piwik.fedorainfracloud.org.cert
|
||||
- piwik.fedorainfracloud.org.key
|
||||
- piwik.fedorainfracloud.org.intermediate.cert
|
||||
tags:
|
||||
- config
|
||||
- piwik
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue