Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add simple ocp4 workload named ocp4_workload_hcp_kubevirt #8866

Merged
merged 1 commit into from
Nov 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
silent: false
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
= ocp4_workload_hcp_kubevirt - Configure OCP to run HCP with OCPv

== Role overview

Simple role to patch Ingress to accept wildcard
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
- name: Running Pre Workload Tasks
when: ACTION == "create" or ACTION == "provision"
ansible.builtin.include_tasks:
file: ./pre_workload.yml

- name: Running Workload Tasks
when: ACTION == "create" or ACTION == "provision"
ansible.builtin.include_tasks:
file: ./workload.yml

- name: Running Post Workload Tasks
when: ACTION == "create" or ACTION == "provision"
ansible.builtin.include_tasks:
file: ./post_workload.yml

- name: Running Workload removal Tasks
when: ACTION == "destroy" or ACTION == "remove"
ansible.builtin.include_tasks:
file: ./remove_workload.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
# Implement your Post Workload deployment tasks here

# Leave this as the last task in the playbook.
- name: Post_workload tasks complete
when: not silent|bool
ansible.builtin.debug:
msg: "Post-Workload Tasks completed successfully."
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
# Implement your Pre Workload deployment tasks here

# Leave this as the last task in the playbook.
- name: Pre_workload tasks complete
when: not silent|bool
ansible.builtin.debug:
msg: "Pre-Workload tasks completed successfully."
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Leave this as the last task in the playbook.
- name: Remove_workload tasks complete
when: not silent | bool
ansible.builtin.debug:
msg: "Remove Workload tasks completed successfully."
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
# Implement your Workload deployment tasks here
- name: Setting up workload for user
ansible.builtin.debug:
msg: "Setting up workload for user ocp_username = {{ ocp_username }}"

- name: Patch the IngressController to allow wildcard routes
kubernetes.core.k8s:
state: patched
namespace: openshift-ingress-operator
api_version: operator.openshift.io/v1
kind: IngressController
name: default
definition:
spec:
routeAdmission:
wildcardPolicy: "WildcardsAllowed"

# Leave this as the last task in the playbook.
- name: Workload tasks complete
when: not silent|bool
ansible.builtin.debug:
msg: "Workload Tasks completed successfully."
Loading