Skip to content

Commit ce82f59

Browse files
committed
moved installs to usr/bin
1 parent 327c645 commit ce82f59

File tree

2 files changed

+5
-27
lines changed

2 files changed

+5
-27
lines changed

ansible/roles/k3s/tasks/main.yml

Lines changed: 4 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -4,57 +4,35 @@
44
ansible.builtin.get_url:
55
url: https://get.k3s.io/
66
timeout: 120
7-
dest: /usr/local/bin/k3s-install.sh
7+
dest: /usr/bin/k3s-install.sh
88
owner: root
99
group: root
1010
mode: "0755"
1111

1212
- name: Install k3s
1313
ansible.builtin.shell:
14-
cmd: /usr/local/bin/k3s-install.sh
14+
cmd: /usr/bin/k3s-install.sh
1515
environment:
1616
INSTALL_K3S_VERSION: "v1.31.0+k3s1"
1717
INSTALL_K3S_EXEC: "{{ item }}"
1818
INSTALL_K3S_SKIP_START: "true"
1919
INSTALL_K3S_SKIP_ENABLE: "true"
20+
INSTALL_K3S_BIN_DIR: "/usr/bin"
2021
changed_when: true
2122
with_items:
2223
- server
2324
- agent
2425

25-
- name: Creating directory on root path
26-
ansible.builtin.file:
27-
path: /root/bin
28-
state: directory
29-
owner: root
30-
31-
- name: Adding symlinks to k3s binaries for root
32-
ansible.builtin.file:
33-
src: /usr/local/bin/k3s
34-
dest: "/root/bin/{{ item }}"
35-
state: link
36-
owner: root
37-
with_items:
38-
- k3s
39-
- kubectl
40-
4126
- name: Installing helm
4227
unarchive:
4328
src: https://get.helm.sh/helm-v3.11.0-linux-amd64.tar.gz
44-
dest: /usr/local/bin
29+
dest: /usr/bin
4530
extra_opts: "--strip-components=1"
4631
owner: root
4732
group: root
4833
mode: 0755
4934
remote_src: true
5035

51-
- name: Add helm symlink in root path
52-
ansible.builtin.file:
53-
src: /usr/local/bin/helm
54-
dest: "/root/bin/helm"
55-
state: link
56-
owner: root
57-
5836
- name: k9s install
5937
ansible.builtin.include_role:
6038
name: k9s

ansible/roles/k9s/tasks/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
- name: Add k9s to root path
1919
ansible.builtin.copy:
2020
src: /root/k9s-temp/k9s
21-
dest: /root/bin/k9s
21+
dest: /usr/bin/k9s
2222
mode: u+rwx
2323
remote_src: yes
2424

0 commit comments

Comments
 (0)