Skip to content

Commit

Permalink
fix: make sure binary install dir exists
Browse files Browse the repository at this point in the history
Signed-off-by: Namjae Kim <[email protected]>
  • Loading branch information
namsic committed Oct 19, 2024
1 parent 909352e commit 2fc5df0
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions roles/_common/tasks/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,24 @@
check_mode: false
when: __common_binary_basename is search('\.zip$|\.tar\.gz$')

- name: "Check existence of binary install dir"
ansible.builtin.stat:
path: "{{ _common_binary_install_dir }}"
register: __common_binary_install_dir

- name: "Make sure binary install dir exists"
ansible.builtin.file:
path: "{{ _common_binary_install_dir }}"
mode: 0755

Check failure on line 113 in roles/_common/tasks/install.yml

View workflow job for this annotation

GitHub Actions / ansible-lint

literal-compare

Don't compare to literal True/False.
owner: root
group: root
become: true
tags:
- "{{ ansible_parent_role_names | first | regex_replace(ansible_collection_name ~ '.', '') }}"
- install
- "{{ ansible_parent_role_names | first | regex_replace(ansible_collection_name ~ '.', '') }}_install"
when: __common_binary_install_dir.stat.exists == false

- name: "Propagate binaries"
ansible.builtin.copy:
src: "{{ _common_local_cache_path }}/{{ item }}"
Expand Down

0 comments on commit 2fc5df0

Please sign in to comment.