51 lines
1.5 KiB
YAML
51 lines
1.5 KiB
YAML
- name: Create folder structure(s)
|
|
ansible.builtin.file:
|
|
path: "{{ item }}"
|
|
state: directory
|
|
loop:
|
|
- /opt/firstboot
|
|
|
|
- name: Create tty console message service
|
|
ansible.builtin.template:
|
|
src: "{{ item.src }}"
|
|
dest: "{{ item.dest }}"
|
|
owner: root
|
|
group: root
|
|
mode: "{{ item.mode | default(omit) }}"
|
|
vars:
|
|
_template:
|
|
service:
|
|
name: ttyConsoleMessage
|
|
executable: /opt/firstboot/tty.sh
|
|
workingdir: /tmp/
|
|
metacluster:
|
|
components:
|
|
- name: ArgoCD
|
|
url: https://gitops.${FQDN}
|
|
healthcheck: https://gitops.${FQDN}
|
|
- name: Gitea
|
|
url: https://git.${FQDN}
|
|
healthcheck: https://git.${FQDN}
|
|
- name: Harbor
|
|
url: https://registry.${FQDN}
|
|
healthcheck: https://registry.${FQDN}
|
|
- name: Longhorn
|
|
url: https://storage.${FQDN}
|
|
healthcheck: https://storage.${FQDN}
|
|
- name: StepCA
|
|
url: ''
|
|
healthcheck: https://ca.${FQDN}/health
|
|
- name: Traefik
|
|
url: https://ingress.${FQDN}
|
|
healthcheck: https://ingress.${FQDN}
|
|
fqdn: "{{ vapp['metacluster.fqdn'] }}"
|
|
vip: "{{ vapp['metacluster.vip'] }}"
|
|
loop:
|
|
- src: tty.j2
|
|
dest: "{{ _template.service.executable }}"
|
|
mode: o+x
|
|
- src: systemdunit.j2
|
|
dest: /etc/systemd/system/{{ _template.service.name }}.service
|
|
loop_control:
|
|
label: "{{ item.src }}"
|