more package fixes
This commit is contained in:
@@ -1,44 +1,44 @@
|
||||
# vim: set filetype=yaml.ansible :
|
||||
---
|
||||
- name: Check if archive already exists
|
||||
- name: Check if go is already installed
|
||||
ansible.builtin.stat:
|
||||
path: "{{ paths.archive }}/{{ go_archive }}"
|
||||
register: stat_go_archive
|
||||
path: "{{ path.go }}/VERSION"
|
||||
register: stat_path_go
|
||||
|
||||
- name: Check version of installed go
|
||||
when:
|
||||
- stat_path_go.stat.exists
|
||||
ansible.builtin.set_fact:
|
||||
do_go_install: "{{ not (go.vers in lookup('ansible.builtin.file', path.go ~ '/VERSION')) }}"
|
||||
|
||||
- name: Install/update go
|
||||
when:
|
||||
- not stat_go_archive.exists
|
||||
- do_go_install or
|
||||
not stat_path_go.stat.exists
|
||||
block:
|
||||
- name: Download go archive
|
||||
become: "{{ sys_pkg_become }}"
|
||||
register: get_url_go
|
||||
ansible.builtin.get_url:
|
||||
dest: "{{ paths.cache }}/{{ go_archive }}"
|
||||
dest: "{{ path.cache }}/{{ go.archive }}"
|
||||
url: "{{ go.url }}"
|
||||
checksum: "{{ go.sum }}"
|
||||
decompress: false
|
||||
mode: '0644'
|
||||
register: get_url_go
|
||||
|
||||
- name: Ensure go install dir exists
|
||||
become: "{{ sys_pkg_become }}"
|
||||
ansible.builtin.file:
|
||||
path: "{{ go.inst_path }}"
|
||||
state: directory
|
||||
mode: '0755'
|
||||
- name: Extract go package for Linux
|
||||
become: "{{ ext_become }}"
|
||||
when:
|
||||
- ansible_system == 'Linux'
|
||||
ansible.builtin.unarchive:
|
||||
dest: "{{ path.prefix }}"
|
||||
src: "{{ d_go_dl_tmp.path }}/{{ go.archive }}"
|
||||
remote_src: true
|
||||
|
||||
- name: Extract go package
|
||||
become: "{{ sys_pkg_become }}"
|
||||
when:
|
||||
- ansible_system == 'Linux'
|
||||
ansible.builtin.unarchive:
|
||||
dest: "{{ paths.archive }}/go"
|
||||
src: "{{ d_go_dl_tmp.path }}/{{ go_archive }}"
|
||||
remote_src: true
|
||||
|
||||
- name: Install go macOS use pkg file
|
||||
become: true
|
||||
when:
|
||||
- ansible_system == 'Darwin'
|
||||
ansible.builtin.command:
|
||||
creates: "{{ go.inst_path }}"
|
||||
cmd: "installer -pkg {{ d_go_dl_tmp.path }}/{{ go_archive }} -target /"
|
||||
- name: Install go macOS using pkg file
|
||||
become: true
|
||||
when:
|
||||
- ansible_distribution == 'MacOSX'
|
||||
ansible.builtin.command:
|
||||
creates: "{{ path.go }}"
|
||||
cmd: "installer -pkg {{ d_go_dl_tmp.path }}/{{ go.archive }} -target /"
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
loop_var: font
|
||||
register: nerdfont_result
|
||||
ansible.builtin.file:
|
||||
path: "{{ nerdfonts.install_path }}/{{ font }}"
|
||||
path: "{{ path.prefix }}/{{ nerdfonts.path }}/{{ font }}"
|
||||
state: directory
|
||||
mode: '0755'
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
loop_control:
|
||||
loop_var: font
|
||||
ansible.builtin.unarchive:
|
||||
creates: "{{ nerdfonts.install_path }}/{{ font }}/README.md"
|
||||
creates: "{{ path.prefix }}/{{ nerdfonts.path }}/{{ font }}/README.md"
|
||||
src: "{{ nerdfonts.base_url }}/{{ font }}.tar.xz"
|
||||
dest: "{{ nerdfonts.install_path }}/{{ font }}"
|
||||
dest: "{{ path.prefix }}/{{ nerdfonts.path }}/{{ font }}"
|
||||
remote_src: true
|
||||
|
||||
Reference in New Issue
Block a user