new host: argentum.binary-kitchen.net (event web)
This commit is contained in:
parent
d10886f284
commit
22c743baec
4
host_vars/argentum.binary-kitchen.net
Normal file
4
host_vars/argentum.binary-kitchen.net
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
---
|
||||||
|
|
||||||
|
root_keys_host:
|
||||||
|
- "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICyGAePGA47K+VNFcKdvcQG3xM3ywcnrVtUD7wPrIin1 christoph"
|
1
hosts
1
hosts
@ -36,4 +36,5 @@ molybdenum.binary-kitchen.net
|
|||||||
ruthenium.binary-kitchen.net
|
ruthenium.binary-kitchen.net
|
||||||
rhodium.binary-kitchen.net
|
rhodium.binary-kitchen.net
|
||||||
palladium.binary-kitchen.net
|
palladium.binary-kitchen.net
|
||||||
|
argentum.binary-kitchen.net
|
||||||
barium.binary-kitchen.net
|
barium.binary-kitchen.net
|
||||||
|
15
roles/event_web/files/certs
Normal file
15
roles/event_web/files/certs
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
---
|
||||||
|
|
||||||
|
eh2x.binary-kitchen.de:
|
||||||
|
- path: /etc/nginx/ssl/eh2x.binary-kitchen.de.crt
|
||||||
|
user: root
|
||||||
|
group: root
|
||||||
|
perm: '400'
|
||||||
|
format: crt,ca
|
||||||
|
action: '/usr/sbin/service nginx restart'
|
||||||
|
- path: /etc/nginx/ssl/eh2x.binary-kitchen.de.key
|
||||||
|
user: root
|
||||||
|
group: root
|
||||||
|
perm: '400'
|
||||||
|
format: key
|
||||||
|
action: '/usr/sbin/service nginx restart'
|
27
roles/event_web/files/vhost
Normal file
27
roles/event_web/files/vhost
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
listen [::]:80;
|
||||||
|
|
||||||
|
server_name eh2x.binary-kitchen.de;
|
||||||
|
|
||||||
|
location /.well-known/acme-challenge {
|
||||||
|
default_type "text/plain";
|
||||||
|
alias /var/www/acme-challenge;
|
||||||
|
}
|
||||||
|
|
||||||
|
location / {
|
||||||
|
return 301 https://eh2x.binary-kitchen.de$request_uri;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 443 ssl http2;
|
||||||
|
listen [::]:443 ssl http2;
|
||||||
|
|
||||||
|
server_name eh2x.binary-kitchen.de;
|
||||||
|
|
||||||
|
ssl_certificate_key /etc/nginx/ssl/eh2x.binary-kitchen.de.key;
|
||||||
|
ssl_certificate /etc/nginx/ssl/eh2x.binary-kitchen.de.crt;
|
||||||
|
|
||||||
|
root /var/www/eh2x;
|
||||||
|
}
|
7
roles/event_web/handlers/main.yml
Normal file
7
roles/event_web/handlers/main.yml
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
|
||||||
|
- name: Restart nginx
|
||||||
|
service: name=nginx state=restarted
|
||||||
|
|
||||||
|
- name: Run acertmgr
|
||||||
|
command: /usr/bin/acertmgr
|
5
roles/event_web/meta/main.yml
Normal file
5
roles/event_web/meta/main.yml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
---
|
||||||
|
|
||||||
|
dependencies:
|
||||||
|
- { role: acertmgr }
|
||||||
|
- { role: nginx, nginx_ssl: True }
|
28
roles/event_web/tasks/main.yml
Normal file
28
roles/event_web/tasks/main.yml
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
---
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
apt:
|
||||||
|
name:
|
||||||
|
- php-fpm
|
||||||
|
|
||||||
|
- name: Create vhost directory
|
||||||
|
file: path=/var/www/eh2x state=directory owner=www-data group=www-data
|
||||||
|
|
||||||
|
- name: Ensure certificates are available
|
||||||
|
command: openssl req -x509 -nodes -newkey rsa:2048 -keyout /etc/nginx/ssl/eh2x.binary-kitchen.de.key -out /etc/nginx/ssl/eh2x.binary-kitchen.de.crt -days 730 -subj "/CN=eh2x.binary-kitchen.de" creates=/etc/nginx/ssl/eh2x.binary-kitchen.de.crt
|
||||||
|
notify: Restart nginx
|
||||||
|
|
||||||
|
#- name: Configure certificate manager
|
||||||
|
# copy: src=certs dest=/etc/acertmgr/eh2x.binary-kitchen.de.conf
|
||||||
|
# notify: Run acertmgr
|
||||||
|
|
||||||
|
- name: Configure vhosts
|
||||||
|
copy: src=vhost dest=/etc/nginx/sites-available/www
|
||||||
|
notify: Restart nginx
|
||||||
|
|
||||||
|
- name: Enable vhosts
|
||||||
|
file: src=/etc/nginx/sites-available/www dest=/etc/nginx/sites-enabled/www state=link
|
||||||
|
notify: Restart nginx
|
||||||
|
|
||||||
|
- name: Start php8.2-fpm
|
||||||
|
service: name=php8.2-fpm state=started enabled=yes
|
7
site.yml
7
site.yml
@ -7,7 +7,7 @@
|
|||||||
- root_keys
|
- root_keys
|
||||||
|
|
||||||
- name: Setup unattended updates
|
- name: Setup unattended updates
|
||||||
hosts: [sulis.binary.kitchen, nabia.binary.kitchen, epona.binary.kitchen, pizza.binary.kitchen, pancake.binary.kitchen, knoedel.binary.kitchen, bob.binary.kitchen, lasagne.binary.kitchen, tschunk.binary.kitchen, bowle.binary.kitchen, beryllium.binary-kitchen.net, boron.binary-kitchen.net, carbon.binary-kitchen.net, nitrogen.binary-kitchen.net, oxygen.binary-kitchen.net, fluorine.binary-kitchen.net, neon.binary-kitchen.net, sodium.binary-kitchen.net, magnesium.binary-kitchen.net, krypton.binary-kitchen.net, yttrium.binary-kitchen.net, zirconium.binary-kitchen.net, molybdenum.binary-kitchen.net, ruthenium.binary-kitchen.net, rhodium.binary-kitchen.net, palladium.binary-kitchen.net, barium.binary-kitchen.net]
|
hosts: [sulis.binary.kitchen, nabia.binary.kitchen, epona.binary.kitchen, pizza.binary.kitchen, pancake.binary.kitchen, knoedel.binary.kitchen, bob.binary.kitchen, lasagne.binary.kitchen, tschunk.binary.kitchen, bowle.binary.kitchen, beryllium.binary-kitchen.net, boron.binary-kitchen.net, carbon.binary-kitchen.net, nitrogen.binary-kitchen.net, oxygen.binary-kitchen.net, fluorine.binary-kitchen.net, neon.binary-kitchen.net, sodium.binary-kitchen.net, magnesium.binary-kitchen.net, krypton.binary-kitchen.net, yttrium.binary-kitchen.net, zirconium.binary-kitchen.net, molybdenum.binary-kitchen.net, ruthenium.binary-kitchen.net, rhodium.binary-kitchen.net, palladium.binary-kitchen.net, argentum.binary-kitchen.net, barium.binary-kitchen.net]
|
||||||
roles:
|
roles:
|
||||||
- uau
|
- uau
|
||||||
|
|
||||||
@ -149,6 +149,11 @@
|
|||||||
roles:
|
roles:
|
||||||
- pretalx
|
- pretalx
|
||||||
|
|
||||||
|
- name: Setup event web host
|
||||||
|
hosts: argentum.binary-kitchen.net
|
||||||
|
roles:
|
||||||
|
- event_web
|
||||||
|
|
||||||
- name: Setup WorkAdventure host
|
- name: Setup WorkAdventure host
|
||||||
hosts: barium.binary-kitchen.net
|
hosts: barium.binary-kitchen.net
|
||||||
roles:
|
roles:
|
||||||
|
Loading…
Reference in New Issue
Block a user