Skip to content

Commit

Permalink
brutella#150 Update include to include_tasks for Ansible v2
Browse files Browse the repository at this point in the history
  • Loading branch information
sighmon committed Nov 19, 2024
1 parent 959d664 commit 6d6910c
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions ansible/roles/hkcam/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
- include: install.yml
- include_tasks: install.yml
tags: [install]

- include: configure.yml
- include_tasks: configure.yml
tags: [configure]

- import_role:
Expand Down
4 changes: 2 additions & 2 deletions ansible/roles/runit/tasks/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
file: path={{ runit_runsvdir_dir }} mode=0755 state=directory

- name: Check if {{ runit_startup_file }} exists
stat: path={{ runit_startup_file }} get_md5=no get_checksum=no
stat: path={{ runit_startup_file }} get_checksum=no
register: file

- name: Create startup script at {{ runit_startup_file }}
Expand All @@ -33,4 +33,4 @@
shell: sed -i -e '$i {{ runit_startup_file }} &\n' /etc/rc.local
args:
warn: false
when: check.rc != 0
when: check is defined and check.rc is defined and check.rc != 0
10 changes: 5 additions & 5 deletions ansible/roles/runit/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
---
- include: install.yml
- include_tasks: install.yml

- include: add.yml
- include_tasks: add.yml
when: service_name is defined

- include: enabled.yml
- include_tasks: enabled.yml
when: enabled is defined and service_name is defined

- include: envs.yml
- include_tasks: envs.yml
when: envs is defined and service_name is defined

- include: state.yml
- include_tasks: state.yml
when: state is defined and service_name is defined

0 comments on commit 6d6910c

Please sign in to comment.