You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
770 B
23 lines
770 B
# stx_repo_dest - Destination directory (relative to Zuul root) |
|
# stx_remote_repo - URL for the repo to pull |
|
# stx_remote_branch - Branch within repo to test |
|
|
|
- hosts: all |
|
pre_tasks: |
|
- name: Determine if repo directory exists already |
|
stat: |
|
path: "{{ stx_repo_dest }}" |
|
register: stx_repo_exists |
|
|
|
- debug: |
|
msg: "Cloning {{ stx_remote_repo }} branch {{ stx_remote_branch }}" |
|
when: stx_repo_exists.stat.isdir is undefined |
|
|
|
- name: Clone remote repo |
|
git: |
|
# repo: https://github.com/starlingx-staging/stx-nova.git |
|
# version: stx/stein.1 |
|
repo: "{{ stx_remote_repo }}" |
|
version: "{{ stx_remote_branch }}" |
|
dest: "{{ stx_repo_dest }}" |
|
when: stx_repo_exists.stat.isdir is undefined
|
|
|