modane_server_playbooks/deploy.yml

53 lines
1.5 KiB
YAML
Raw Normal View History

2024-06-08 09:37:02 +00:00
- name: Construct inventory
hosts: localhost
tasks:
- name: add new instance to host group at runtime
ansible.builtin.add_host:
name: "{{ target_name }}"
groups: target
changed_when: false
- name: Configure Modane server
hosts: target
gather_facts: false
2024-06-14 18:47:34 +00:00
vars_files:
- vars/main.yml
2024-06-08 09:37:02 +00:00
tasks:
- name: Gather facts
ansible.builtin.setup:
- name: Include role_unpack_secrets
ansible.builtin.include_role:
name: role_unpack_secrets
vars:
LOCAL_AND_REMOTE: true
- name: Include secrets from yml db
ansible.builtin.include_vars: "{{ local_workdir }}/secrets/secrets.yml"
2024-06-14 18:47:34 +00:00
- name: Include deploy_reverse-proxy tasks
ansible.builtin.include_tasks: "tasks/deploy_reverse-proxy.yml"
tags: deploy_reverse-proxy
2024-06-08 09:37:02 +00:00
- name: Create homeassistant container
containers.podman.podman_container:
name: homeassistant
image: ghcr.io/home-assistant/home-assistant:2024.3
network:
- host
env:
TZ: "Europe/Paris"
privileged: true
restart_policy: always
volume:
- /mnt/apps/volumes/homeassistant_conf:/config
become: true
2024-06-08 19:45:32 +00:00
- name: Include deploy_thermostat tasks
ansible.builtin.include_tasks: "tasks/deploy_thermostat.yml"
tags: deploy_thermostat
2024-06-08 09:37:02 +00:00
2024-06-08 19:45:32 +00:00
- name: Include deploy_sensors-polling tasks
ansible.builtin.include_tasks: "tasks/deploy_sensors-polling.yml"
tags: deploy_sensors-polling