more fixs for packages
This commit is contained in:
@@ -3,7 +3,8 @@
|
||||
- name: Set facts for installation
|
||||
ansible.builtin.set_fact:
|
||||
ext_become: "{{ not use_local }}"
|
||||
path_prefix: "{% if use_local %}{{ lookup('ansible.builtin.env', 'HOME') }}/.local{% else %}{{ defaults.path.prefix }}{% endif %}"
|
||||
path:
|
||||
prefix: "{% if use_local %}{{ lookup('ansible.builtin.env', 'HOME') }}/.local{% else %}{{ defaults.path.prefix }}{% endif %}"
|
||||
|
||||
- name: Set Linux specific facts
|
||||
when:
|
||||
@@ -18,6 +19,14 @@
|
||||
pkg_snap: [] # snpacraft.io packages
|
||||
sys_pkg_become: true # Linux package managers require sudo access
|
||||
|
||||
- name: Set rpm dist if RedHat based
|
||||
when:
|
||||
- ansible_os_family == 'RedHat'
|
||||
changed_when: false
|
||||
register: rpm_dist
|
||||
ansible.builtin.command:
|
||||
cmd: rpm --eval "%{dist}"
|
||||
|
||||
- name: Set macOS specific facts
|
||||
when:
|
||||
- ansible_distribution == 'MacOSX'
|
||||
@@ -30,13 +39,14 @@
|
||||
|
||||
- name: Set paths
|
||||
ansible.builtin.set_fact:
|
||||
paths:
|
||||
appimage: "{{ appimage_path | default(path_prefix ~ defaults.path.suffix.appimage) }}"
|
||||
archive: "{{ archive_path | default(path_prefix ~ defaults.path.suffix.archive) }}"
|
||||
bin: "{{ bin_path | default(path_prefix ~ defaults.path.suffix.bin) }}"
|
||||
cargo: "{{ cargo_path | default(path_prefix ~ defaults.path.suffix.cargo) }}"
|
||||
go: "{{ goroot | default(path_prefix ~ defaults.path.suffix.go) }}"
|
||||
pipx: "{{ pipx_path | default(path_prefix ~ defaults.path.suffix.pipx) }}"
|
||||
path:
|
||||
prefix: "{{ path.prefix }}"
|
||||
appimage: "{{ path.appimage | default(path.prefix ~ defaults.path.suffix.appimage) }}"
|
||||
archive: "{{ path.archive | default(path.prefix ~ defaults.path.suffix.archive) }}"
|
||||
bin: "{{ path.bin | default(path.prefix ~ defaults.path.suffix.bin) }}"
|
||||
cargo: "{{ path.cargo | default(path.prefix ~ defaults.path.suffix.cargo) }}"
|
||||
go: "{{ path.go | default(path.prefix ~ defaults.path.suffix.go) }}"
|
||||
pipx: "{{ path.pipx | default(path.prefix ~ defaults.path.suffix.pipx) }}"
|
||||
|
||||
- name: Set OS independant facts
|
||||
ansible.builtin.set_fact:
|
||||
|
||||
Reference in New Issue
Block a user