fix: don't nest vars to improve UX

Signed-off-by: Matej Focko <me@mfocko.xyz>
This commit is contained in:
Matej Focko 2023-08-31 11:52:00 +02:00
parent eb6d77de65
commit 0d359aa19f
Signed by: mfocko
GPG key ID: 7C47D46246790496
7 changed files with 26 additions and 45 deletions

View file

@ -7,18 +7,11 @@ desktops:
ohm: ohm:
vars: vars:
sshd: sshd_port: 22
port: 22 sshd_sign_host_keys: false
sshd_auth_password_authentication: "yes"
auth: flatpak_apps:
permit_root_login: "no"
password_authentication: "yes"
trusted_ca: true
sign_host_keys: false
flatpak:
apps:
- com.chatterino.chatterino - com.chatterino.chatterino
- com.discordapp.Discord - com.discordapp.Discord
- com.spotify.Client - com.spotify.Client

View file

@ -3,12 +3,4 @@ servers:
hosts: hosts:
poincare: poincare:
maxwell: maxwell:
sshd: sshd_port: 6969
port: 6969
auth:
permit_root_login: "no"
password_authentication: "no"
trusted_ca: true
sign_host_keys: true

View file

@ -1,3 +1,2 @@
--- ---
flatpak: flatpak_apps: []
apps: []

View file

@ -11,5 +11,5 @@
community.general.packaging.os.flatpak: community.general.packaging.os.flatpak:
name: "{{ item }}" name: "{{ item }}"
state: present state: present
loop: "{{ flatpak.apps }}" loop: "{{ flatpak_apps }}"
when: flatpak.apps when: flatpak_apps

View file

@ -1,10 +1,7 @@
--- ---
sshd: sshd_port: 10022
port: 10022 sshd_sign_host_keys: true
auth: sshd_auth_permit_root_login: "no"
permit_root_login: "no" sshd_auth_password_authentication: "no"
password_authentication: "no" sshd_auth_trusted_ca: true
trusted_ca: true
sign_host_keys: true

View file

@ -29,4 +29,4 @@
- name: Set trusted CA - name: Set trusted CA
ansible.builtin.include_tasks: trusted_ca.yml ansible.builtin.include_tasks: trusted_ca.yml
when: sshd.auth.trusted_ca when: sshd_auth_trusted_ca

View file

@ -1,6 +1,6 @@
# Port # Port
Port {{ sshd.port }} Port {{ sshd_port }}
# Auth # Auth
PermitRootLogin {{ sshd.auth.permit_root_login }} PermitRootLogin {{ sshd_auth_permit_root_login }}
PasswordAuthentication {{ sshd.auth.password_authentication }} PasswordAuthentication {{ sshd_auth_password_authentication }}