Merge pull request #1223 from mattymo/vault_cert_skip
Skip vault cert task evaluation when using script certs
This commit is contained in:
commit
07ea95a9bf
5 changed files with 28 additions and 28 deletions
|
@ -1,4 +1,12 @@
|
||||||
---
|
---
|
||||||
|
- include: sync_etcd_master_certs.yml
|
||||||
|
when: inventory_hostname in groups.etcd
|
||||||
|
tags: etcd-secrets
|
||||||
|
|
||||||
|
- include: sync_etcd_node_certs.yml
|
||||||
|
when: inventory_hostname in etcd_node_cert_hosts
|
||||||
|
tags: etcd-secrets
|
||||||
|
|
||||||
|
|
||||||
- name: gen_certs_vault | Read in the local credentials
|
- name: gen_certs_vault | Read in the local credentials
|
||||||
command: cat /etc/vault/roles/etcd/userpass
|
command: cat /etc/vault/roles/etcd/userpass
|
||||||
|
@ -75,3 +83,5 @@
|
||||||
with_items: "{{ etcd_node_certs_needed|d([]) }}"
|
with_items: "{{ etcd_node_certs_needed|d([]) }}"
|
||||||
when: inventory_hostname in etcd_node_cert_hosts
|
when: inventory_hostname in etcd_node_cert_hosts
|
||||||
notify: set etcd_secret_changed
|
notify: set etcd_secret_changed
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -7,20 +7,7 @@
|
||||||
when: cert_management == "script"
|
when: cert_management == "script"
|
||||||
tags: [etcd-secrets, facts]
|
tags: [etcd-secrets, facts]
|
||||||
|
|
||||||
- include: gen_certs_script.yml
|
- include: "gen_certs_{{ cert_management }}.yml"
|
||||||
when: cert_management == "script"
|
|
||||||
tags: etcd-secrets
|
|
||||||
|
|
||||||
- include: sync_etcd_master_certs.yml
|
|
||||||
when: cert_management == "vault" and inventory_hostname in groups.etcd
|
|
||||||
tags: etcd-secrets
|
|
||||||
|
|
||||||
- include: sync_etcd_node_certs.yml
|
|
||||||
when: cert_management == "vault" and inventory_hostname in etcd_node_cert_hosts
|
|
||||||
tags: etcd-secrets
|
|
||||||
|
|
||||||
- include: gen_certs_vault.yml
|
|
||||||
when: cert_management == "vault" and (etcd_master_certs_needed|d() or etcd_node_certs_needed|d())
|
|
||||||
tags: etcd-secrets
|
tags: etcd-secrets
|
||||||
|
|
||||||
- include: "install_{{ etcd_deployment_type }}.yml"
|
- include: "install_{{ etcd_deployment_type }}.yml"
|
||||||
|
|
|
@ -1,4 +1,11 @@
|
||||||
---
|
---
|
||||||
|
- include: sync_kube_master_certs.yml
|
||||||
|
when: inventory_hostname in groups['kube-master']
|
||||||
|
tags: k8s-secrets
|
||||||
|
|
||||||
|
- include: sync_kube_node_certs.yml
|
||||||
|
when: inventory_hostname in groups['k8s-cluster']
|
||||||
|
tags: k8s-secrets
|
||||||
|
|
||||||
- name: gen_certs_vault | Read in the local credentials
|
- name: gen_certs_vault | Read in the local credentials
|
||||||
command: cat /etc/vault/roles/kube/userpass
|
command: cat /etc/vault/roles/kube/userpass
|
||||||
|
|
|
@ -74,13 +74,5 @@
|
||||||
- include: "gen_certs_{{ cert_management }}.yml"
|
- include: "gen_certs_{{ cert_management }}.yml"
|
||||||
tags: k8s-secrets
|
tags: k8s-secrets
|
||||||
|
|
||||||
- include: sync_kube_master_certs.yml
|
|
||||||
when: cert_management == "vault" and inventory_hostname in groups['kube-master']
|
|
||||||
tags: k8s-secrets
|
|
||||||
|
|
||||||
- include: sync_kube_node_certs.yml
|
|
||||||
when: cert_management == "vault" and inventory_hostname in groups['k8s-cluster']
|
|
||||||
tags: k8s-secrets
|
|
||||||
|
|
||||||
- include: gen_tokens.yml
|
- include: gen_tokens.yml
|
||||||
tags: k8s-secrets
|
tags: k8s-secrets
|
||||||
|
|
|
@ -13,6 +13,10 @@
|
||||||
-v /etc/vault:/etc/vault
|
-v /etc/vault:/etc/vault
|
||||||
{{ vault_image_repo }}:{{ vault_version }} server
|
{{ vault_image_repo }}:{{ vault_version }} server
|
||||||
|
|
||||||
|
#FIXME(mattymo): Crashes on first start with aufs docker storage. See hashicorp/docker-vault#19
|
||||||
|
- name: bootstrap/start_vault_temp | Start again single node Vault with file backend
|
||||||
|
command: docker start {{ vault_temp_container_name }}
|
||||||
|
|
||||||
- name: bootstrap/start_vault_temp | Initialize vault-temp
|
- name: bootstrap/start_vault_temp | Initialize vault-temp
|
||||||
uri:
|
uri:
|
||||||
url: "http://localhost:{{ vault_port }}/v1/sys/init"
|
url: "http://localhost:{{ vault_port }}/v1/sys/init"
|
||||||
|
|
Loading…
Reference in a new issue