diff --git a/roles/install_yamls/README.md b/roles/install_yamls/README.md index e613a87c38..11cc7ada02 100644 --- a/roles/install_yamls/README.md +++ b/roles/install_yamls/README.md @@ -6,6 +6,8 @@ It contains a set of playbooks to deploy podified control plane. ## Parameters +* `cifmw_installyamls_repo_url`: (String) Url of the install_yamls repo. Defaults to `https://github.com/openstack-k8s-operators/install_yamls`. +* `cifmw_install_yamls_version`: (String) Version of the repo to be cloned. Defaults to `HEAD`. * `cifmw_install_yamls_envfile`: (String) Environment file containing all the Makefile overrides. Defaults to `install_yamls`. * `cifmw_install_yamls_out_dir`: (String) `install_yamls` output directory to store generated output. Defaults to `{{ cifmw_basedir | default(ansible_user_dir ~ '/ci-framework-data') }}/artifacts"`. * `cifmw_install_yamls_vars`: (Dict) A dict containing Makefile overrides. diff --git a/roles/install_yamls/defaults/main.yml b/roles/install_yamls/defaults/main.yml index c45baff3ce..9704be4d57 100644 --- a/roles/install_yamls/defaults/main.yml +++ b/roles/install_yamls/defaults/main.yml @@ -28,6 +28,8 @@ cifmw_install_yamls_edpm_dir: "{{ cifmw_manifests | default(cifmw_install_yamls_ # NAMESPACE: openstack # METALLB_POOL would be removed once https://github.com/openstack-k8s-operators/install_yamls/pull/356 merges. cifmw_install_yamls_repo: "{{ cifmw_installyamls_repos | default(ansible_user_dir ~ '/src/github.com/openstack-k8s-operators/install_yamls') }}" +cifmw_installyamls_repo_url: "https://github.com/openstack-k8s-operators/install_yamls" +cifmw_install_yamls_version: "HEAD" cifmw_install_yamls_tasks_out: "{{ cifmw_install_yamls_out_dir }}/roles/install_yamls_makes/tasks" cifmw_install_yamls_whitelisted_vars: - DEPLOY_DIR diff --git a/roles/install_yamls/tasks/main.yml b/roles/install_yamls/tasks/main.yml index f9705ab7f8..146488498a 100644 --- a/roles/install_yamls/tasks/main.yml +++ b/roles/install_yamls/tasks/main.yml @@ -26,6 +26,15 @@ - "{{ cifmw_install_yamls_tasks_out }}" - "{{ cifmw_basedir }}/artifacts/parameters" +- name: Ensure install_yamls repo is present at the desired version + tags: + - bootstrap + ansible.builtin.git: + repo: "{{ cifmw_installyamls_repo_url }}" + dest: "{{ cifmw_install_yamls_repo }}" + version: "{{ cifmw_install_yamls_version }}" + update: false + - name: Create variables with local repos based on Zuul items tags: - bootstrap