-
Notifications
You must be signed in to change notification settings - Fork 107
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'openstack-k8s-operators:main' into multiple_nodesets
- Loading branch information
Showing
105 changed files
with
2,430 additions
and
418 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,3 +6,4 @@ docs/dictionary/tmp | |
.vscode | ||
.venv/* | ||
.env | ||
.idea/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
--- | ||
# Purpose of this playbook: | ||
# - Create a virtual infrastructure consisting in | ||
# virtual machines, related storage, and virtual networks. | ||
# | ||
# - Create a dnsmasq instance with the appropriate records to provide | ||
# fixed IPs, proper DNS resolution | ||
# | ||
# - Expose at least one inventory file showing the various resources | ||
# | ||
# This playbook is meant to run for architecture driven deployment only. | ||
|
||
- name: Parent scenario if needed | ||
hosts: "{{ cifmw_target_host | default('localhost') }}" | ||
gather_facts: true | ||
tasks: | ||
- name: Inherit from parent scenarios if needed | ||
ansible.builtin.include_tasks: | ||
file: "ci/playbooks/tasks/inherit_parent_scenario.yml" | ||
|
||
- name: Manage/generate unique ID | ||
ansible.builtin.import_playbook: playbooks/unique-id.yml | ||
|
||
- name: Run consistency checks | ||
ansible.builtin.import_playbook: "playbooks/adoption/pre.yml" | ||
|
||
- name: Prepare infrastructure datasets | ||
ansible.builtin.import_playbook: "playbooks/adoption/infra.yml" | ||
|
||
- name: Amend infrastructure datasets | ||
hosts: "{{ cifmw_target_host | default('localhost') }}" | ||
gather_facts: true | ||
tasks: | ||
# Inject "start: false" in the layout to not start any VM yet. | ||
# Starting the VM will be done later, either by the tool deploying | ||
# OSP, or the one deploy RHOSO. | ||
# VM initial configuration, when managed, is done using cloud-init. | ||
- name: Ensure no VM is started when we create them during this run | ||
vars: | ||
_no_start: >- | ||
{% set _vms = {} -%} | ||
{% for _type in _cifmw_libvirt_manager_layout.vms.keys() -%} | ||
{% set _ = _vms.update({_type: {'start': false}}) -%} | ||
{% endfor -%} | ||
{{ _vms }} | ||
ansible.builtin.set_fact: | ||
_cifmw_libvirt_manager_layout: >- | ||
{{ | ||
_cifmw_libvirt_manager_layout | | ||
combine({'vms': _no_start}, recursive=true) | ||
}} | ||
- name: Set amount for OCP cluster members to 0 | ||
vars: | ||
_0_ocp: | ||
vms: | ||
ocp: | ||
amount: 0 | ||
ocp_worker: | ||
amount: 0 | ||
ansible.builtin.set_fact: | ||
_cifmw_libvirt_manager_layout: >- | ||
{{ | ||
_cifmw_libvirt_manager_layout | combine(_0_ocp, recursive=true) | ||
}} | ||
- name: Prepare networking | ||
ansible.builtin.import_playbook: "playbooks/adoption/network.yml" | ||
|
||
- name: Deploy infrastructure | ||
hosts: "{{ cifmw_target_host | default('localhost') }}" | ||
gather_facts: true | ||
tasks: | ||
# Create all the VMs | ||
- name: Deploy layout | ||
ansible.builtin.import_role: | ||
name: "libvirt_manager" | ||
tasks_from: "deploy_layout.yml" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
--- | ||
# This playbook deploy OCP, both master and workers. | ||
# The main goal of this playbook is to be called as | ||
# a standalone piece of a bigger job, mostly in the | ||
# adoption context. | ||
# | ||
# You would typically run this playbook after the | ||
# "create-infra.yml" one, passing the exact same parameters. | ||
# | ||
# Make sure you passed the needed secrets to deploy OCP! | ||
|
||
- name: Parent scenario if needed | ||
hosts: "{{ cifmw_target_host | default('localhost') }}" | ||
gather_facts: true | ||
tasks: | ||
- name: Inherit from parent scenarios if needed | ||
ansible.builtin.include_tasks: | ||
file: "ci/playbooks/tasks/inherit_parent_scenario.yml" | ||
|
||
- name: Manage/generate unique ID | ||
ansible.builtin.import_playbook: playbooks/unique-id.yml | ||
|
||
- name: Run consistency checks | ||
ansible.builtin.import_playbook: "playbooks/adoption/pre.yml" | ||
|
||
- name: Prepare infrastructure datasets | ||
ansible.builtin.import_playbook: "playbooks/adoption/infra.yml" | ||
|
||
- name: Amend infrastructure datasets | ||
hosts: "{{ cifmw_target_host | default('localhost') }}" | ||
gather_facts: true | ||
tasks: | ||
# Inject "start: false" in the layout to not start any VM yet. | ||
# Starting the VM will be done later, either by the tool deploying | ||
# OSP, or the one deploy RHOSO. | ||
# VM initial configuration, when managed, is done using cloud-init. | ||
- name: Ensure no VM is started when we create them during this run | ||
vars: | ||
_no_start: >- | ||
{% set _vms = {} -%} | ||
{% for _type in _cifmw_libvirt_manager_layout.vms.keys() -%} | ||
{% if _type is not match('^ocp.*') -%} | ||
{% set _ = _vms.update({_type: {'start': false}}) -%} | ||
{% endif -%} | ||
{% endfor -%} | ||
{{ _vms }} | ||
ansible.builtin.set_fact: | ||
_cifmw_libvirt_manager_layout: >- | ||
{{ | ||
_cifmw_libvirt_manager_layout | | ||
combine({'vms': _no_start}, recursive=true) | ||
}} | ||
- name: Prepare networking | ||
ansible.builtin.import_playbook: "playbooks/adoption/network.yml" | ||
|
||
- name: OCP cluster | ||
hosts: "{{ cifmw_target_host | default('localhost') }}" | ||
gather_facts: true | ||
tasks: | ||
- name: Deploy OCP cluster | ||
ansible.builtin.import_role: | ||
name: "reproducer" | ||
tasks_from: "ocp_layout.yml" | ||
|
||
- name: Start OCP cluster based on its overlays | ||
ansible.builtin.import_role: | ||
name: "libvirt_manager" | ||
tasks_from: "deploy_layout.yml" | ||
|
||
# Run from the hypervisor | ||
- name: Ensure OCP cluster is stable | ||
vars: | ||
_auth_path: >- | ||
{{ | ||
( | ||
cifmw_devscripts_repo_dir, | ||
'ocp', | ||
cifmw_devscripts_config.cluster_name, | ||
'auth' | ||
) | ansible.builtin.path_join | ||
}} | ||
cifmw_openshift_adm_op: "stable" | ||
cifmw_openshift_kubeconfig: >- | ||
{{ (_auth_path, 'kubeconfig') | ansible.builtin.path_join }} | ||
ansible.builtin.include_role: | ||
name: openshift_adm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -496,6 +496,7 @@ tempestconf | |
testcases | ||
testenv | ||
timestamper | ||
timesync | ||
tldca | ||
tls | ||
tmp | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# Catalog entry for Backstage [backstage.io] | ||
|
||
apiVersion: backstage.io/v1alpha1 | ||
kind: Component | ||
metadata: | ||
name: ci-framework | ||
title: ci-framework | ||
description: | | ||
CI Framework - used for CI, QE and Devs to run OSP 18+ jobs in a converged way | ||
annotations: | ||
github.com/project-slug: openstack-k8s-operators/ci-framework | ||
feedback/type: JIRA | ||
feedback/host: https://issues.redhat.com | ||
jira/project-key: OSPRH | ||
links: | ||
- title: docs | ||
url: https://ci-framework.readthedocs.io/en/latest/ | ||
icon: docs | ||
- title: code | ||
url: https://github.com/openstack-k8s-operators/ci-framework | ||
icon: github | ||
- title: "#osp-podified-ci-support" | ||
url: https://app.slack.com/client/E030G10V24F/C03MD4LG22Z | ||
icon: chat | ||
tags: | ||
- testing | ||
- test-execution | ||
- test-framework | ||
- test-management | ||
- test-reporting | ||
- provisioning | ||
- python | ||
- openstack | ||
- openshift | ||
- cloud | ||
- continuous-integration | ||
namespace: quality-community | ||
spec: | ||
type: tool | ||
owner: group:redhat/openstack-k8s-operators-ci | ||
lifecycle: production |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
--- | ||
# Purpose: create infra dataset to be consumed by | ||
# adoption related playbooks | ||
|
||
- name: Create CI virtual infrastructure | ||
hosts: "{{ cifmw_target_host | default('localhost') }}" | ||
gather_facts: true | ||
roles: | ||
- role: ci_setup | ||
- role: discover_latest_image | ||
|
||
tasks: | ||
- name: Generate libvirt layout | ||
ansible.builtin.include_role: | ||
name: "libvirt_manager" | ||
tasks_from: "generate_layout.yml" | ||
|
||
- name: Apply layout patches if it exists | ||
when: | ||
- _adoption_scenario.libvirt_manager_patch_layout is defined | ||
ansible.builtin.set_fact: | ||
_cifmw_libvirt_manager_layout: >- | ||
{{ | ||
_cifmw_libvirt_manager_layout | | ||
combine(_adoption_scenario.libvirt_manager_patch_layout, | ||
recursive=true) | ||
}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
--- | ||
# Purpose: create infra dataset to be consumed by | ||
# adoption related playbooks | ||
|
||
- name: Build networking_mapper related content | ||
hosts: "{{ cifmw_target_host | default('localhost') }}" | ||
gather_facts: true | ||
tasks: | ||
- name: Apply networking_definition patch if it exists | ||
when: | ||
- _adoption_scenario.networking_mapper_definition_patch is defined | ||
ansible.builtin.set_fact: | ||
cifmw_networking_mapper_definition_patch_01_adoption_infra: >- | ||
{{ _adoption_scenario.networking_mapper_definition_patch }} | ||
- name: Prepare networking | ||
vars: | ||
cifmw_reproducer_validate_network: false | ||
_use_crc: false | ||
_use_ocp: true | ||
ansible.builtin.import_role: | ||
name: "reproducer" | ||
tasks_from: "prepare_networking.yml" |
Oops, something went wrong.