Add service playbook and test run for prod gerrit

We need to test this against production variables too.

Change-Id: I7813787506e3b70ef0960ce85dccca4eb9ec7a3f
This commit is contained in:
Monty Taylor 2019-10-25 12:09:29 +09:00
parent 7c86c4d067
commit 1d37be64b4
4 changed files with 25 additions and 1 deletions

View File

@ -1020,19 +1020,29 @@
nodes:
- name: bridge.openstack.org
label: ubuntu-bionic
- name: review01.opendev.org
label: ubuntu-bionic
- name: review-dev01.openstack.org
label: ubuntu-bionic
vars:
run_playbooks:
- playbooks/service-review-dev.yaml
- playbooks/service-review.yaml
host-vars:
review-dev01.openstack.org:
host_copy_output:
'/home/gerrit2/review_site/etc': logs
'/home/gerrit2/review_site/logs': logs
review01.opendev.org:
host_copy_output:
'/home/gerrit2/review_site/etc': logs
'/home/gerrit2/review_site/logs': logs
files:
- playbooks/group_vars/review.yaml
- ^playbooks/host_vars/review\d+.opendev.org.yaml
- playbooks/group_vars/review-dev.yaml
- ^playbooks/host_vars/review-dev\d+.opendev.org.yaml
- playbooks/zuul/templates/group_vars/review-dev.yaml.j2
- playbooks/zuul/templates/group_vars/review.yaml.j2
- playbooks/roles/gerrit/
- testinfra/test_gerrit.py

View File

@ -0,0 +1,6 @@
- hosts: "review:!disabled"
name: "Configure gerrit"
roles:
- pip3
- install-podman
- gerrit

View File

@ -27,3 +27,8 @@ gerrit_ssh_rsa_key_contents: |
Pb95AevPUxqqAKNZYsj4yDsXnmbFSHARijPWcpfkCDJmVhMFPObr4OE=
-----END RSA PRIVATE KEY-----
gerrit_ssh_rsa_pubkey_contents: ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC+pCQlTAQYmCrOY6aPbvbyKQDcOCXibPNGIjnPPMuEItCS0vtRnqEBz7znWZS5Drq9yKpROh6uFF01ao2VnNjw6f+NdRNV19RWVe6mYN+qa2VrH2caLwBrKPiH0Xc/eK41D55dZU7IWwKYAw/NpiBaBfHavFwipI+rmEb68MH2hcimDdr/bji+0hkh3X+42dkNvmMdtkuCW6nKdAEhnXaHZc5SJR/EvzgRCfB8vbML13p46O9xhoJgn7ZWvMb3vaR5jxIkQwstUR36raEVhttBDEuWasWnHYbrM1zd3ooudbTEQf5vXISZKFygHyJFFqb4iQ76i+hDlb0VQKZCdaol gerrit-code-review@829f141b0fa5
gerrit_database_config_section: |
[database]
type = h2
database = tmp/ReviewDB
gerrit_run_init: true

View File

@ -13,7 +13,10 @@
# under the License.
testinfra_hosts = ['review-dev01.openstack.org']
testinfra_hosts = [
'review-dev01.openstack.org',
'review01.opendev.org',
]
def test_gerrit_listening(host):