- hosts: "review" tasks: - name: Wait for Gerrit to be up uri: url: http://localhost:8081/a/accounts/admin/sshkeys method: GET user: admin password: secret register: result until: result.status == 200 and not result.redirected delay: 1 retries: 120 - name: Create Zuul user uri: url: http://localhost:8081/a/accounts/zuul method: PUT user: admin password: secret body_format: json body: name: 'Zuul' email: 'zuul@example.com' http_password: 'secret' status_code: 201 - name: Create temp dir for project creation shell: mktemp -d register: project_tmp - name: Create project project in Gerrit uri: url: http://localhost:8081/a/projects/test-project method: PUT user: admin password: secret status_code: 201 - name: Create initial commit and change in test-project shell: executable: /bin/sh chdir: "{{ project_tmp.stdout }}" cmd: | set -x git init . git config user.name "Admin" git config user.email "admin@example.com" cat >.gitreview <file.txt <