-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Victor Morales <[email protected]>
- Loading branch information
1 parent
da5077f
commit 4f7a760
Showing
9 changed files
with
81 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
|
||
crun_version: 0.15 | ||
crun_release_url: https://github.com/containers/crun/releases/download/{{ crun_version }}/crun-{{ crun_version }}-linux-{{ host_architecture }} | ||
crun_bin_dir: /usr/bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
|
||
- name: Create binary destination folder | ||
file: | ||
mode: '0755' | ||
state: directory | ||
path: "{{ crun_bin_dir }}" | ||
|
||
- name: Check if binary exists | ||
stat: | ||
path: "{{ crun_bin_dir }}/crun" | ||
register: crun_stat | ||
|
||
- name: Download binary | ||
get_url: | ||
url: "{{ crun_release_url }}" | ||
dest: "{{ crun_bin_dir }}/crun" | ||
mode: '0755' | ||
when: not crun_stat.stat.exists |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
roles/kubernetes-apps/container_runtimes/crun/files/runtimeclass-crun.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
kind: RuntimeClass | ||
apiVersion: node.k8s.io/v1beta1 | ||
metadata: | ||
name: crun | ||
handler: crun |
19 changes: 19 additions & 0 deletions
19
roles/kubernetes-apps/container_runtimes/crun/tasks/main.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
|
||
- name: crun | Copy runtime class manifest | ||
copy: | ||
src: runtimeclass-crun.yml | ||
dest: "{{ kube_config_dir }}/runtimeclass-crun.yml" | ||
mode: preserve | ||
when: | ||
- inventory_hostname == groups['kube-master'][0] | ||
|
||
- name: crun | Apply manifests | ||
kube: | ||
name: "runtimeclass-crun" | ||
kubectl: "{{ bin_dir }}/kubectl" | ||
resource: "runtimeclass" | ||
filename: "{{ kube_config_dir }}/runtimeclass-crun.yml" | ||
state: "latest" | ||
when: | ||
- inventory_hostname == groups['kube-master'][0] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters