-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Fabricio Aguiar <fabricio.aguiar@gmail.com>
- Loading branch information
Showing
5 changed files
with
78 additions
and
45 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,27 @@ | ||
--- | ||
# note by default the source for the playbook specified | ||
# in the hooks is relative to | ||
# https://github.com/openstack-k8s-operators/ci-framework/tree/main/hooks/playbooks | ||
# if you want to use a different source you can use the full path on the ansible controller | ||
|
||
post_ctlplane_deploy: | ||
- name: 71 Kustomize control plane to enable heat service | ||
cifmw_edpm_prepare_timeout: 60 | ||
pre_deploy_create_coo_subscription: | ||
source: "{{ ansible_user_dir }}/{{ zuul.projects['github.com/openstack-k8s-operators/heat-operator'].src_dir }}/ci/tempest/create-coo-subscription-playbook.yaml" | ||
type: playbook | ||
source: "{{ ansible_user_dir }}/{{ zuul.projects['github.com/openstack-k8s-operators/heat-operator'].src_dir }}/ci/tempest/control_plane_hook.yaml" | ||
- name: 82 Kustomize and update Control Plane | ||
type: playbook | ||
source: control_plane_kustomize_deploy.yml | ||
cifmw_edpm_prepare_kustomizations: | ||
- apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
namespace: openstack | ||
patches: | ||
- patch: |- | ||
apiVersion: core.openstack.org/v1beta1 | ||
kind: OpenStackControlPlane | ||
metadata: | ||
name: unused | ||
spec: | ||
heat: | ||
enabled: true | ||
telemetry: | ||
enabled: true | ||
template: | ||
metricStorage: | ||
enabled: true | ||
autoscaling: | ||
enabled: true | ||
target: | ||
kind: OpenStackControlPlane |
This file was deleted.
Oops, something went wrong.
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,10 @@ | ||
--- | ||
- name: "Create the cluster-observability-operator subscription" | ||
hosts: "{{ cifmw_target_hook_host | default('localhost') }}" | ||
gather_facts: false | ||
environment: | ||
KUBECONFIG: "{{ cifmw_openshift_kubeconfig }}" | ||
PATH: "{{ cifmw_path }}" | ||
tasks: | ||
- name: Import tasks for creating COO subscription | ||
ansible.builtin.include_tasks: "create-coo-subscription.yaml" |
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,33 @@ | ||
--- | ||
- name: Create the COO subscription | ||
ansible.builtin.shell: | ||
cmd: | | ||
oc create -f - <<EOF | ||
apiVersion: operators.coreos.com/v1alpha1 | ||
kind: Subscription | ||
metadata: | ||
name: cluster-observability-operator | ||
namespace: openshift-operators | ||
spec: | ||
channel: development | ||
installPlanApproval: Automatic | ||
name: cluster-observability-operator | ||
source: redhat-operators | ||
sourceNamespace: openshift-marketplace | ||
EOF | ||
register: output | ||
|
||
# need to have a wait here, since the csv is not created immediately. There is a slight delay, during which time, the oc wait command would fail, since there's no resource to watch | ||
- name: Wait for the required resource to be created | ||
ansible.builtin.command: | ||
cmd: | ||
oc get csv --namespace=openshift-operators -l operators.coreos.com/cluster-observability-operator.openshift-operators | ||
delay: 10 | ||
retries: 20 | ||
register: output | ||
until: output.stdout_lines | length != 0 | ||
|
||
- name: Wait for the resources to be available | ||
ansible.builtin.command: | ||
cmd: | | ||
oc wait --timeout=300s --for jsonpath="{.status.phase}"=Succeeded csv --namespace=openshift-operators -l operators.coreos.com/cluster-observability-operator.openshift-operators |
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