Switch to shell module
Some checks reported errors
continuous-integration/drone/push Build encountered an error

This commit is contained in:
Danny Bessems 2022-04-20 09:16:55 +02:00
parent 75d1e95238
commit 29f7ebf14a

View File

@ -66,19 +66,22 @@
groups: k3s_ha groups: k3s_ha
with_items: "{{ nodes }}" with_items: "{{ nodes }}"
# - name: Scan public keys - name: Scan public keys
# ansible.builtin.shell: ansible.builtin.shell:
# cmd: "ssh-keyscan -t rsa {{ item.ip }}" cmd: "ssh-keyscan -t rsa {{ item.ip }}"
# register: publickeys register: publickeys
# with_items: "{{ nodes }}" with_items: "{{ nodes }}"
# - name: Store public keys - ansible.builtin.debug:
# ansible.builtin.known_hosts: var: publickeys
# name: "{{ item.item }}"
# key: "{{ item.stdout }}" - name: Store public keys
# state: present ansible.builtin.known_hosts:
# path: ~/.ssh/known_hosts name: "{{ item.item }}"
# with_items: "{{ publickeys.results }}" key: "{{ item.stdout }}"
state: present
path: ~/.ssh/known_hosts
with_items: "{{ publickeys.results }}"
- name: Provision Kubernetes - name: Provision Kubernetes
hosts: k3s_ha hosts: k3s_ha