Use infra-prod-base in infra-prod jobs
This uses a new base job which handles pushing the git repos on to bridge since that must now happen in a trusted playbook. Depends-On: https://review.opendev.org/742934 Change-Id: Ie6d0668f83af801c0c0e920b676f2f49e19c59f6
This commit is contained in:
parent
2f7959d5f2
commit
b9f7f5506f
@ -1,36 +1,5 @@
|
|||||||
- hosts: localhost
|
|
||||||
tasks:
|
|
||||||
- name: Add bridge.o.o to inventory
|
|
||||||
add_host:
|
|
||||||
name: bridge.openstack.org
|
|
||||||
ansible_python_interpreter: python3
|
|
||||||
ansible_user: zuul
|
|
||||||
# Without setting ansible_host directly, mirror-workspace-git-repos
|
|
||||||
# gets sad because if delegate_to localhost and with add_host that
|
|
||||||
# ends up with ansible_host being localhost.
|
|
||||||
ansible_host: bridge.openstack.org
|
|
||||||
ansible_port: 22
|
|
||||||
|
|
||||||
- hosts: localhost
|
|
||||||
tasks:
|
|
||||||
- name: Add bridge.o.o hostkey to known hosts
|
|
||||||
known_hosts:
|
|
||||||
name: bridge.openstack.org
|
|
||||||
key: "bridge.openstack.org ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCxRzDkWvvVQtsLTAqAwedRWA84/42KKVdFS0QP8lZFsMpgTXUhjipJ7VcFun5gM87tnt0J71rlN+ospBh0/1wfp2jASEskUyGhXAa5xHjnJN7veUyW+AggEosK/OTunvZgf54p1sQg45Sq/uCjc0Ua0fRMOq2o5z/mgpl6rSjLOlWi9wKA/6axnUbs9w4iD5esyBQ+VcISSJOTqhAo/3UG0NwCU+6Ggwwhg0nl5iCMpQfq4A207IbJ72MkJzlQgW3edsRb5POzdZcGxkTYvVdP3kgHP4Bof3MFFZjBUMz6SuRQyNV5poysMtbtlO0SvgAJNhXr6Vn0GA9XhqFP6+HT"
|
|
||||||
|
|
||||||
- hosts: bridge.openstack.org
|
- hosts: bridge.openstack.org
|
||||||
tasks:
|
tasks:
|
||||||
- name: Make sure a manaul maint isn't going on
|
|
||||||
wait_for:
|
|
||||||
path: /home/zuul/DISABLE-ANSIBLE
|
|
||||||
state: absent
|
|
||||||
sleep: 10
|
|
||||||
timeout: 3600 # Wait for an hour before bailing
|
|
||||||
|
|
||||||
- name: Synchronize src repos to workspace directory.
|
|
||||||
include_role:
|
|
||||||
name: prepare-workspace-git
|
|
||||||
|
|
||||||
- name: Should we run from master
|
- name: Should we run from master
|
||||||
set_fact:
|
set_fact:
|
||||||
infra_prod_run_from_master: "{{ zuul.pipeline|default('') in ['periodic', 'opendev-prod-hourly'] }}"
|
infra_prod_run_from_master: "{{ zuul.pipeline|default('') in ['periodic', 'opendev-prod-hourly'] }}"
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
|
|
||||||
- job:
|
- job:
|
||||||
name: infra-prod-playbook
|
name: infra-prod-playbook
|
||||||
|
parent: opendev-infra-prod-base
|
||||||
description: |
|
description: |
|
||||||
Run specified playbook against productions hosts.
|
Run specified playbook against productions hosts.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user