From 0945eb990a138d418f33855139e6e96d2abca639 Mon Sep 17 00:00:00 2001 From: Matthew Mosesohn Date: Thu, 19 Apr 2018 16:47:20 +0300 Subject: [PATCH] Make it possible to skip docker role as a var (#2686) --- cluster.yml | 2 +- roles/kubespray-defaults/defaults/main.yaml | 4 ++++ scale.yml | 2 +- upgrade-cluster.yml | 2 +- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/cluster.yml b/cluster.yml index fb7dec4cb..b4a48985f 100644 --- a/cluster.yml +++ b/cluster.yml @@ -33,7 +33,7 @@ roles: - { role: kubespray-defaults} - { role: kubernetes/preinstall, tags: preinstall } - - { role: docker, tags: docker } + - { role: docker, tags: docker, when: manage_docker|default(true) } - role: rkt tags: rkt when: "'rkt' in [etcd_deployment_type, kubelet_deployment_type, vault_deployment_type]" diff --git a/roles/kubespray-defaults/defaults/main.yaml b/roles/kubespray-defaults/defaults/main.yaml index 82df06f21..f297c007e 100644 --- a/roles/kubespray-defaults/defaults/main.yaml +++ b/roles/kubespray-defaults/defaults/main.yaml @@ -129,6 +129,10 @@ kube_apiserver_insecure_port: 8080 # Aggregator kube_api_aggregator_routing: false +# Docker options +# Optionally do not run docker role +manage_docker: true + # Path used to store Docker data docker_daemon_graph: "/var/lib/docker" diff --git a/scale.yml b/scale.yml index bcf6c69b0..3f8613011 100644 --- a/scale.yml +++ b/scale.yml @@ -28,7 +28,7 @@ roles: - { role: kubespray-defaults} - { role: kubernetes/preinstall, tags: preinstall } - - { role: docker, tags: docker } + - { role: docker, tags: docker, when: manage_docker|default(true) } - role: rkt tags: rkt when: "'rkt' in [etcd_deployment_type, kubelet_deployment_type, vault_deployment_type]" diff --git a/upgrade-cluster.yml b/upgrade-cluster.yml index 7acec3083..9e858acd3 100644 --- a/upgrade-cluster.yml +++ b/upgrade-cluster.yml @@ -34,7 +34,7 @@ roles: - { role: kubespray-defaults} - { role: kubernetes/preinstall, tags: preinstall } - - { role: docker, tags: docker } + - { role: docker, tags: docker, when: manage_docker|default(true) } - role: rkt tags: rkt when: "'rkt' in [etcd_deployment_type, kubelet_deployment_type, vault_deployment_type]"