Skip to content

Commit

Permalink
refactor: use community.docker instead of community.general
Browse files Browse the repository at this point in the history
  • Loading branch information
artyorsh committed Aug 14, 2024
1 parent 58f002c commit 1ab67d0
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 9 deletions.
1 change: 0 additions & 1 deletion .github/workflows/test-ubuntu-lts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ jobs:
/opt/pipx/venvs/ansible-core/bin/python -m pip install requests
ansible-galaxy install geerlingguy.docker
ansible-galaxy collection install community.general
ansible-galaxy collection install community.docker
ansible-galaxy collection install . -f
Expand Down
4 changes: 2 additions & 2 deletions roles/homeassistant/tasks/homeassistant.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@

- name: "Ensure {{ homeassistant_network }} network exists"
when: homeassistant_network != "host"
community.general.docker_network:
community.docker.docker_network:
name: "{{ homeassistant_network }}"
state: "present"

- name: "Run homeassistant container"
community.general.docker_container:
community.docker.docker_container:
name: "{{ homeassistant_service_id }}"
image: "{{ homeassistant_avahi_image_name }}:{{ homeassistant_avahi_image_tag }}"
networks:
Expand Down
4 changes: 2 additions & 2 deletions roles/homeassistant/tasks/mdns.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

- name: "Get homeassistant network interface name"
block:
- community.general.docker_network_info:
- community.docker.docker_network_info:
name: "{{ ha_network }}"
register: ha_network_info

Expand All @@ -26,7 +26,7 @@
line: "allow-interfaces={{ homeassistant_mdns_host_network_interface }},{{ homeassistant_mdns_docker_network_interface }}"

- name: "Run mdns-repeater container"
community.general.docker_container:
community.docker.docker_container:
name: "{{ homeassistant_mdns_service_id }}"
image: "angelnu/mdns_repeater"
network_mode: "host"
Expand Down
4 changes: 2 additions & 2 deletions roles/mosquitto/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,12 @@

- name: "Ensure {{ mosquitto_network }} network exists"
when: mosquitto_network != "host"
community.general.docker_network:
community.docker.docker_network:
name: "{{ mosquitto_network }}"
state: "present"

- name: "Run mosquitto container"
community.general.docker_container:
community.docker.docker_container:
name: "{{ mosquitto_service_id }}"
image: "eclipse-mosquitto:{{ mosquitto_version }}"
networks:
Expand Down
4 changes: 2 additions & 2 deletions roles/zigbee2mqtt/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@

- name: "Ensure {{ zigbee2mqtt_network }} network exists"
when: zigbee2mqtt_network != "host"
community.general.docker_network:
community.docker.docker_network:
name: "{{ zigbee2mqtt_network }}"
state: "present"

- name: "Run zigbee2mqtt container"
community.general.docker_container:
community.docker.docker_container:
name: "{{ zigbee2mqtt_service_id }}"
image: "koenkk/zigbee2mqtt:{{ zigbee2mqtt_version }}"
networks:
Expand Down

0 comments on commit 1ab67d0

Please sign in to comment.