diff options
author | pmikus <pmikus@cisco.com> | 2021-03-08 12:08:26 +0000 |
---|---|---|
committer | Peter Mikus <pmikus@cisco.com> | 2021-03-22 08:48:48 +0000 |
commit | 180603b936083afe5006af514b18b4e870cbc0fd (patch) | |
tree | 1870bdf1fe5804830f03b086204ff30730c93ad6 | |
parent | 31663d7fbfb05a9b94731982ab858a30bf04d800 (diff) |
Infra: Do not strict check keys in Ansible
- not until we migrate to SSH keys in ubuntu 2004
Signed-off-by: pmikus <pmikus@cisco.com>
Change-Id: I796f86922c672ba053d64f317cf6adb46b845cac
(cherry picked from commit 221e2f4da7cb27954525d973d930cb8db4601c8f)
(cherry picked from commit e18995fcebbf83806d93bb01b2d210e12a75a970)
-rw-r--r-- | resources/libraries/bash/function/ansible.sh | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/resources/libraries/bash/function/ansible.sh b/resources/libraries/bash/function/ansible.sh index 1263412dd5..f522faa93b 100644 --- a/resources/libraries/bash/function/ansible.sh +++ b/resources/libraries/bash/function/ansible.sh @@ -1,6 +1,6 @@ #!/usr/bin/env bash -# Copyright (c) 2020 Cisco and/or its affiliates. +# Copyright (c) 2021 Cisco and/or its affiliates. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at: @@ -34,9 +34,10 @@ function ansible_adhoc () { die "Failed to read hosts from working topology!" } pushd "${TOOLS_DIR}"/testbed-setup/ansible || die "Pushd failed!" - ANSIBLE_STDOUT_CALLBACK=yaml \ - ANSIBLE_PIPELINING=true \ - ansible \ + export ANSIBLE_HOST_KEY_CHECKING=False + export ANSIBLE_STDOUT_CALLBACK=yaml + export ANSIBLE_PIPELINING=true + ansible-playbook \ --vault-password-file=vault_pass \ --extra-vars '@vault.yml' \ --inventory inventories/lf_inventory/hosts site.yaml \ @@ -65,9 +66,10 @@ function ansible_playbook () { die "Failed to read hosts from working topology!" } pushd "${TOOLS_DIR}"/testbed-setup/ansible || die "Pushd failed!" - ANSIBLE_STDOUT_CALLBACK=yaml \ - ANSIBLE_PIPELINING=true \ - ansible-playbook \ + export ANSIBLE_HOST_KEY_CHECKING=False + export ANSIBLE_STDOUT_CALLBACK=yaml + export ANSIBLE_PIPELINING=true + ansible-playbook \ --vault-password-file=vault_pass \ --extra-vars '@vault.yml' \ --inventory inventories/lf_inventory/hosts site.yaml \ |