1
0
Fork 0

Compare commits

..

No commits in common. "61a891ae241aafeb5596289a88175c3ae66fe6a0" and "270f03a7026f225d53672d2427bc11fecae610e8" have entirely different histories.

8 changed files with 12 additions and 13 deletions

View File

@ -47,7 +47,6 @@ haproxy:
- deluge.badjware.dev - deluge.badjware.dev
- tavern.badjware.dev - tavern.badjware.dev
- actual.badjware.dev - actual.badjware.dev
- openai.badjware.dev
backend: backend:
- server: 192.168.20.20:8443 - server: 192.168.20.20:8443
- server: 192.168.20.21:8443 - server: 192.168.20.21:8443

View File

@ -1,4 +1,4 @@
k3s: k3s:
version: v1.31.4+k3s1 version: v1.28.8+k3s1
# disable local-path-provisioner, we use longhorn instead # disable local-path-provisioner, we use longhorn instead
extra_server_args: --disable local-storage extra_server_args: --disable local-storage

4
hosts
View File

@ -36,8 +36,8 @@ all:
nut_client: nut_client:
ups: liebert-psi ups: liebert-psi
sched: sched:
# We want to shutdown this server quicker # We want to shutdown this server quick
on_bat: 60 on_bat: 15
bastion: bastion:
hosts: hosts:
bastion: bastion:

View File

@ -1,3 +0,0 @@
- hosts: k3s-agent0,k3s-agent1,k3s-agent2,k3s-agent3
tasks:
- reboot:

View File

@ -42,3 +42,9 @@
dest: /opt/certbot/certbot-deploy.sh dest: /opt/certbot/certbot-deploy.sh
mode: '0700' mode: '0700'
notify: Run certbot notify: Run certbot
- name: Install weekly haproxy reload
cron:
name: "haproxy reload"
special_time: weekly
job: "/bin/systemctl reload haproxy"

View File

@ -1,3 +1,2 @@
#!/bin/sh #!/bin/sh
cat /etc/letsencrypt/live/{{ letsencrypt.domains[0] }}/fullchain.pem /etc/letsencrypt/live/{{ letsencrypt.domains[0] }}/privkey.pem >/etc/letsencrypt/live/{{ letsencrypt.domains[0] }}/{{ letsencrypt.domains[0] }}.pem cat /etc/letsencrypt/live/{{ letsencrypt.domains[0] }}/fullchain.pem /etc/letsencrypt/live/{{ letsencrypt.domains[0] }}/privkey.pem >/etc/letsencrypt/live/{{ letsencrypt.domains[0] }}/{{ letsencrypt.domains[0] }}.pem
systemctl restart haproxy

View File

@ -1,7 +1,7 @@
SUBSYSTEM!="usb", GOTO="nut-usbups_rules_end" SUBSYSTEM!="usb", GOTO="nut-usbups_rules_end"
{% for name, config in nut_server.ups.items() %} {% for name, config in nut_server.ups.items() %}
ACTION=="add|change", SUBSYSTEM=="usb|usb_device", SUBSYSTEMS=="usb|usb_device", ATTR{idVendor}=="{{ config.vendorid }}", ATTR{idProduct}=="{{ config.productid }}", MODE="664", GROUP="nut", RUN+="/sbin/upsdrvctl stop || /sbin/upsdrvctl start" ACTION=="add|change", SUBSYSTEM=="usb|usb_device", SUBSYSTEMS=="usb|usb_device", ATTR{idVendor}=="{{ config.vendorid }}", ATTR{idProduct}=="{{ config.productid }}", MODE="664", GROUP="nut", RUN+="/sbin/upsdrvctl stop; /sbin/upsdrvctl start"
{% endfor %} {% endfor %}
LABEL="nut-usbups_rules_end" LABEL="nut-usbups_rules_end"

View File

@ -22,19 +22,17 @@
creates: /etc/wireguard/private.key creates: /etc/wireguard/private.key
register: private_key_gen register: private_key_gen
- name: Read private key - name: Fetch private key
command: cat /etc/wireguard/private.key command: cat /etc/wireguard/private.key
register: private_key register: private_key
changed_when: false
- name: Generate public key - name: Generate public key
shell: cat /etc/wireguard/private.key | wg pubkey >/etc/wireguard/public.key shell: cat /etc/wireguard/private.key | wg pubkey >/etc/wireguard/public.key
when: not public_key_stats.stat.exists or private_key_gen.changed when: not public_key_stats.stat.exists or private_key_gen.changed
- name: Read public key - name: Fetch public key
command: cat /etc/wireguard/public.key command: cat /etc/wireguard/public.key
register: public_key register: public_key
changed_when: false
- name: Print public key - name: Print public key
debug: debug: