From 5e6aa5e70df0552a88c9503dfae5ba9621ec16b4 Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Sat, 25 Apr 2020 09:45:44 -0500 Subject: [PATCH] Use python3 for ansible We get deprecation warnings from ansible about use of python2 on xenial hosts. Rather than setting ansible_python_interpreter to python3 on a host by host basis, set it globally to python3. Set it to python for the one host that's too old, refstack.openstack.org, which is running on trusty which only has python3.4. Change-Id: I4965d950c13efad80d72912911bc7099e9da1659 --- playbooks/group_vars/all.yaml | 2 ++ playbooks/group_vars/gitea.yaml | 1 - playbooks/group_vars/zuul-preview.yaml | 1 - playbooks/host_vars/adns1.opendev.org.yaml | 1 - playbooks/host_vars/bridge.openstack.org.yaml | 1 - playbooks/host_vars/etherpad01.opendev.org.yaml | 1 - playbooks/host_vars/insecure-ci-registry01.opendev.org.yaml | 1 - playbooks/host_vars/mirror01.dfw.rax.opendev.org.yaml | 1 - playbooks/host_vars/mirror01.gra1.ovh.opendev.org.yaml | 1 - playbooks/host_vars/mirror01.iad.rax.opendev.org.yaml | 1 - .../host_vars/mirror01.kna1.airship-citycloud.opendev.org.yaml | 1 - playbooks/host_vars/mirror01.ord.rax.opendev.org.yaml | 1 - .../host_vars/mirror01.regionone.linaro-us.opendev.org.yaml | 1 - playbooks/host_vars/mirror01.us-east.openedge.opendev.org.yaml | 1 - playbooks/host_vars/mirror02.mtl01.inap.opendev.org.yaml | 1 - playbooks/host_vars/nb04.opendev.org.yaml | 1 - playbooks/host_vars/ns1.opendev.org.yaml | 1 - playbooks/host_vars/ns2.opendev.org.yaml | 1 - playbooks/host_vars/refstack.openstack.org.yaml | 1 + playbooks/host_vars/review-dev01.opendev.org.yaml | 1 - playbooks/host_vars/static01.opendev.org.yaml | 1 - 21 files changed, 3 insertions(+), 19 deletions(-) create mode 100644 playbooks/host_vars/refstack.openstack.org.yaml diff --git a/playbooks/group_vars/all.yaml b/playbooks/group_vars/all.yaml index fb1b08f61a..00e5488fdc 100644 --- a/playbooks/group_vars/all.yaml +++ b/playbooks/group_vars/all.yaml @@ -1,3 +1,5 @@ +ansible_python_interpreter: python3 + distro_lookup_path: - "{{ ansible_facts.distribution }}.{{ ansible_facts.lsb.codename }}.{{ ansible_facts.architecture }}.yaml" - "{{ ansible_facts.distribution }}.{{ ansible_facts.lsb.codename }}.yaml" diff --git a/playbooks/group_vars/gitea.yaml b/playbooks/group_vars/gitea.yaml index 19eedab34a..1934a54338 100644 --- a/playbooks/group_vars/gitea.yaml +++ b/playbooks/group_vars/gitea.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 gitea_root_email: infra-root@openstack.org gitea_gerrit_public_key: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDVuhTMAz1H2Jr9AC3py9A0vlNna6Sdt4yrvZOayxukPqQ7GPZd+Mo7MVyypxLD479N2mA09JAdsbq1eTiPP8ksEkB+dNxZzw8mY1653R/IXSW6J9xPcoDa88HF2s/xHN24IWzgiDjNNe79AQ+sKleByEQZ++xXny3MRpy258hKUvAtjjOLOnM1PBs8JNOzBL+UPgWRgSX6GG0qywJZqjD1Qx5kvH9RTRLi+tcMhEi4laN7BYvn4csY0sYzTzPG4ZTu3ootIJoRlQGtQ0LmoFO1vSwyEJUags6/ZZGjgy3jl3kwcU/b8ZnFlF4MDw1OB1QqMb4r6bMHbXNIupp4zJbz gerrit-replication-2014-04-25 iptables_extra_public_tcp_ports: diff --git a/playbooks/group_vars/zuul-preview.yaml b/playbooks/group_vars/zuul-preview.yaml index 902c874cd6..2ff4864007 100644 --- a/playbooks/group_vars/zuul-preview.yaml +++ b/playbooks/group_vars/zuul-preview.yaml @@ -1,3 +1,2 @@ -ansible_python_interpreter: python3 iptables_extra_public_tcp_ports: - 80 diff --git a/playbooks/host_vars/adns1.opendev.org.yaml b/playbooks/host_vars/adns1.opendev.org.yaml index 71b79291b7..e69de29bb2 100644 --- a/playbooks/host_vars/adns1.opendev.org.yaml +++ b/playbooks/host_vars/adns1.opendev.org.yaml @@ -1 +0,0 @@ -ansible_python_interpreter: python3 diff --git a/playbooks/host_vars/bridge.openstack.org.yaml b/playbooks/host_vars/bridge.openstack.org.yaml index ef960d17d9..b311f43390 100644 --- a/playbooks/host_vars/bridge.openstack.org.yaml +++ b/playbooks/host_vars/bridge.openstack.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 bastion_key_exclusive: false kube_config_template: clouds/bridge_kube_config.yaml.j2 extra_users: diff --git a/playbooks/host_vars/etherpad01.opendev.org.yaml b/playbooks/host_vars/etherpad01.opendev.org.yaml index 98f8fb05bb..836990ce04 100644 --- a/playbooks/host_vars/etherpad01.opendev.org.yaml +++ b/playbooks/host_vars/etherpad01.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 etherpad_vhost_name: etherpad.opendev.org letsencrypt_certs: etherpad01-opendev-org-main: diff --git a/playbooks/host_vars/insecure-ci-registry01.opendev.org.yaml b/playbooks/host_vars/insecure-ci-registry01.opendev.org.yaml index 5000fdd4f3..05a656d83a 100644 --- a/playbooks/host_vars/insecure-ci-registry01.opendev.org.yaml +++ b/playbooks/host_vars/insecure-ci-registry01.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: insecure-ci-registry01-main: - insecure-ci-registry01.opendev.org diff --git a/playbooks/host_vars/mirror01.dfw.rax.opendev.org.yaml b/playbooks/host_vars/mirror01.dfw.rax.opendev.org.yaml index cc69fb5593..05d6b18ada 100644 --- a/playbooks/host_vars/mirror01.dfw.rax.opendev.org.yaml +++ b/playbooks/host_vars/mirror01.dfw.rax.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: mirror01-dfw-rax-main: - mirror01.dfw.rax.opendev.org diff --git a/playbooks/host_vars/mirror01.gra1.ovh.opendev.org.yaml b/playbooks/host_vars/mirror01.gra1.ovh.opendev.org.yaml index 0df8cea49f..b4271d6a92 100644 --- a/playbooks/host_vars/mirror01.gra1.ovh.opendev.org.yaml +++ b/playbooks/host_vars/mirror01.gra1.ovh.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: mirror01-gra1-ovh-main: - mirror01.gra1.ovh.opendev.org diff --git a/playbooks/host_vars/mirror01.iad.rax.opendev.org.yaml b/playbooks/host_vars/mirror01.iad.rax.opendev.org.yaml index e01c985571..c679adcae5 100644 --- a/playbooks/host_vars/mirror01.iad.rax.opendev.org.yaml +++ b/playbooks/host_vars/mirror01.iad.rax.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: mirror01-iad-rax-main: - mirror01.iad.rax.opendev.org diff --git a/playbooks/host_vars/mirror01.kna1.airship-citycloud.opendev.org.yaml b/playbooks/host_vars/mirror01.kna1.airship-citycloud.opendev.org.yaml index b5b3ba4046..5d061aa6d3 100644 --- a/playbooks/host_vars/mirror01.kna1.airship-citycloud.opendev.org.yaml +++ b/playbooks/host_vars/mirror01.kna1.airship-citycloud.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: mirror01-kna1-airship-citycloud-main: - mirror01.kna1.airship-citycloud.opendev.org diff --git a/playbooks/host_vars/mirror01.ord.rax.opendev.org.yaml b/playbooks/host_vars/mirror01.ord.rax.opendev.org.yaml index 4adab57cb3..c3d9e69887 100644 --- a/playbooks/host_vars/mirror01.ord.rax.opendev.org.yaml +++ b/playbooks/host_vars/mirror01.ord.rax.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: mirror01-ord-rax-main: - mirror01.ord.rax.opendev.org diff --git a/playbooks/host_vars/mirror01.regionone.linaro-us.opendev.org.yaml b/playbooks/host_vars/mirror01.regionone.linaro-us.opendev.org.yaml index e45d2ce2c0..2762eb3804 100644 --- a/playbooks/host_vars/mirror01.regionone.linaro-us.opendev.org.yaml +++ b/playbooks/host_vars/mirror01.regionone.linaro-us.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: mirror01-regionone-linaro-us-main: - mirror01.regionone.linaro-us.opendev.org diff --git a/playbooks/host_vars/mirror01.us-east.openedge.opendev.org.yaml b/playbooks/host_vars/mirror01.us-east.openedge.opendev.org.yaml index 6345fab32a..0462efbda6 100644 --- a/playbooks/host_vars/mirror01.us-east.openedge.opendev.org.yaml +++ b/playbooks/host_vars/mirror01.us-east.openedge.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: mirror01-us-east-openedge-main: - mirror01.us-east.openedge.opendev.org diff --git a/playbooks/host_vars/mirror02.mtl01.inap.opendev.org.yaml b/playbooks/host_vars/mirror02.mtl01.inap.opendev.org.yaml index fd7cfb3af8..343b0a53b2 100644 --- a/playbooks/host_vars/mirror02.mtl01.inap.opendev.org.yaml +++ b/playbooks/host_vars/mirror02.mtl01.inap.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: mirror02-mtl01-inap-main: - mirror02.mtl01.inap.opendev.org diff --git a/playbooks/host_vars/nb04.opendev.org.yaml b/playbooks/host_vars/nb04.opendev.org.yaml index 4f707ad6ba..76bdf697bb 100644 --- a/playbooks/host_vars/nb04.opendev.org.yaml +++ b/playbooks/host_vars/nb04.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: nb04-opendev-org-main: - nb04.opendev.org diff --git a/playbooks/host_vars/ns1.opendev.org.yaml b/playbooks/host_vars/ns1.opendev.org.yaml index 71b79291b7..e69de29bb2 100644 --- a/playbooks/host_vars/ns1.opendev.org.yaml +++ b/playbooks/host_vars/ns1.opendev.org.yaml @@ -1 +0,0 @@ -ansible_python_interpreter: python3 diff --git a/playbooks/host_vars/ns2.opendev.org.yaml b/playbooks/host_vars/ns2.opendev.org.yaml index 71b79291b7..e69de29bb2 100644 --- a/playbooks/host_vars/ns2.opendev.org.yaml +++ b/playbooks/host_vars/ns2.opendev.org.yaml @@ -1 +0,0 @@ -ansible_python_interpreter: python3 diff --git a/playbooks/host_vars/refstack.openstack.org.yaml b/playbooks/host_vars/refstack.openstack.org.yaml new file mode 100644 index 0000000000..89224a3fb2 --- /dev/null +++ b/playbooks/host_vars/refstack.openstack.org.yaml @@ -0,0 +1 @@ +ansible_python_interpreter: python diff --git a/playbooks/host_vars/review-dev01.opendev.org.yaml b/playbooks/host_vars/review-dev01.opendev.org.yaml index 919a60c41c..fb145c7329 100644 --- a/playbooks/host_vars/review-dev01.opendev.org.yaml +++ b/playbooks/host_vars/review-dev01.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: review-dev01-opendev-org-main: - review-dev.opendev.org diff --git a/playbooks/host_vars/static01.opendev.org.yaml b/playbooks/host_vars/static01.opendev.org.yaml index c585e4d388..604cf1cdf0 100644 --- a/playbooks/host_vars/static01.opendev.org.yaml +++ b/playbooks/host_vars/static01.opendev.org.yaml @@ -1,4 +1,3 @@ -ansible_python_interpreter: python3 letsencrypt_certs: static01-opendev-org-main: - static.opendev.org