bootstrap: connect as root via deploy SSH key (racknerd uses PermitRootLogin without-password)
This commit is contained in:
parent
26cce822c0
commit
03cbaaef3a
@ -106,9 +106,11 @@
|
|||||||
managed_user: ansible
|
managed_user: ansible
|
||||||
new_hostname: "{{ new_hostname | default('racknerd1') }}"
|
new_hostname: "{{ new_hostname | default('racknerd1') }}"
|
||||||
ansible_user: "{{ connect_user | default('root') }}"
|
ansible_user: "{{ connect_user | default('root') }}"
|
||||||
ansible_password: "{{ hostvars['localhost'].pc_root_pass }}"
|
# Connect as root using the deploy SSH key (written to the runner temp file in precheck).
|
||||||
ansible_become_password: "{{ hostvars['localhost'].pc_root_pass }}"
|
# racknerd-class hosts use PermitRootLogin without-password, so password auth won't work;
|
||||||
ansible_ssh_common_args: "-o StrictHostKeyChecking=accept-new"
|
# the deploy key must already be in root's authorized_keys (one-time seeding).
|
||||||
|
ansible_ssh_private_key_file: "/tmp/bootstrap_deploy_key"
|
||||||
|
ansible_ssh_common_args: "-o StrictHostKeyChecking=accept-new -o IdentitiesOnly=yes"
|
||||||
managed_ssh_pubkey: "{{ hostvars['localhost'].pc_ssh_pubkey }}"
|
managed_ssh_pubkey: "{{ hostvars['localhost'].pc_ssh_pubkey }}"
|
||||||
managed_user_password: "{{ hostvars['localhost'].pc_user_pass }}"
|
managed_user_password: "{{ hostvars['localhost'].pc_user_pass }}"
|
||||||
cleanup_paths: []
|
cleanup_paths: []
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user