-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #172 from grycap/cri-dockerd
Add support to cri-dockerd #168
- Loading branch information
Showing
13 changed files
with
158 additions
and
29 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -61,12 +61,9 @@ The variables that can be passed to this role and a brief description about them | |
# Email to be used in the Let's Encrypt issuer | ||
kube_cert_user_email: [email protected] | ||
# Override default docker version | ||
# (installed when not in kube_docker_compatible_versions) | ||
kube_docker_version: "" | ||
# Options to add in the docker.json file | ||
kube_docker_options: {} | ||
# Compatible docker versions | ||
kube_docker_compatible_versions: ['17.03.', '18.06.', '18.09.', '19.03.'] | ||
# Install docker with pip | ||
kube_install_docker_pip | ||
# Command flags to use for launching k3s in the systemd service | ||
|
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
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,36 @@ | ||
--- | ||
- name: Download cri-dockerd tarball | ||
get_url: | ||
url: https://github.com/Mirantis/cri-dockerd/releases/download/v{{ kube_cri_dockerd_version }}/cri-dockerd-{{ kube_cri_dockerd_version }}.amd64.tgz | ||
dest: /tmp/cri-dockerd-{{ kube_cri_dockerd_version }}.amd64.tgz | ||
|
||
- name: Extract cri-dockerd tarball | ||
unarchive: | ||
src: /tmp/cri-dockerd-{{ kube_cri_dockerd_version }}.amd64.tgz | ||
dest: /tmp | ||
remote_src: yes | ||
|
||
- name: Copy cri-dockerd binary | ||
copy: | ||
src: /tmp/cri-dockerd/cri-dockerd | ||
dest: /usr/bin/cri-dockerd | ||
mode: '0755' | ||
|
||
- name: Download cri-docker service and socket | ||
get_url: | ||
url: https://raw.githubusercontent.com/Mirantis/cri-dockerd/master/packaging/systemd/{{ item }} | ||
dest: /etc/systemd/system/{{ item }} | ||
mode: '0644' | ||
loop: | ||
- cri-docker.service | ||
- cri-docker.socket | ||
|
||
- name: Enable cri-dockerd service | ||
systemd: | ||
name: "{{ item }}" | ||
enabled: yes | ||
daemon_reload: yes | ||
state: started | ||
loop: | ||
- cri-docker.service | ||
- cri-docker.socket |
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,21 @@ | ||
--- | ||
kind: JoinConfiguration | ||
{% if kube_version is version_compare('1.22.0', '<') %} | ||
apiVersion: kubeadm.k8s.io/v1beta2 | ||
{% else %} | ||
apiVersion: kubeadm.k8s.io/v1beta3 | ||
{% endif %} | ||
nodeRegistration: | ||
kubeletExtraArgs: | ||
cgroup-driver: systemd | ||
{% for key, value in kubelet_extra_args_dict.items() %} | ||
{{key}}: {{value}} | ||
{% endfor %} | ||
{% if kube_cri_runtime == "docker" %} | ||
criSocket: "/run/cri-dockerd.sock" | ||
{% endif %} | ||
discovery: | ||
bootstrapToken: | ||
token: "{{kube_token}}" | ||
apiServerEndpoint: {{kube_server}}:6443 | ||
unsafeSkipCAVerification: true |
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,17 @@ | ||
--- | ||
- hosts: localhost | ||
roles: | ||
- role: ansible-role-kubernetes | ||
kube_install_metrics: true | ||
kube_cert_manager: true | ||
kube_install_kubeapps: false | ||
kube_install_kyverno: false | ||
kube_deploy_dashboard: true | ||
kube_install_ingress: true | ||
kube_public_dns_name: test.domain.com | ||
kube_version: 1.25.3 | ||
kube_cri_runtime: docker | ||
kube_cri_runtime_install: false | ||
kube_install_docker_pip: true | ||
kubelet_extra_args_dict: | ||
node-labels: somelabel |
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