diff --git a/molecule/default/playbook-no-deploy.yml b/molecule/default/playbook-no-deploy.yml index 127fbf5..831b989 100644 --- a/molecule/default/playbook-no-deploy.yml +++ b/molecule/default/playbook-no-deploy.yml @@ -19,5 +19,8 @@ - hello: world k3s_node_taints: - key1: value1:NoExecute + k3s_kubelet_args: + - cloud-provider: external + - provider-id: azure roles: - role: xanmanning.k3s diff --git a/tasks/validate/check-variables.yml b/tasks/validate/check-variables.yml index 29a1f23..3999bec 100644 --- a/tasks/validate/check-variables.yml +++ b/tasks/validate/check-variables.yml @@ -118,6 +118,14 @@ fail_msg: "Node Taints are not supported in {{ k3s_release_version }}" when: k3s_node_taints is defined and k3s_node_taints +- name: Check k3s_kubelet_args against k3s version + assert: + that: + - (k3s_release_version | replace('v', '')) is version_compare('0.4.0', '>=') + success_msg: "Kubelet args supported in {{ k3s_release_version }}" + fail_msg: "Kubelet args are not supported in {{ k3s_release_version }}" + when: k3s_kubelet_args is defined and k3s_kubelet_args | length > 0 + - name: Check k3s_flannel_backend against k3s version assert: that: