openshift_app_spices
Ansible role for OpenShift Operators
Ansible to configure https://try.openshift.com[OpenShift] cluster for Red Hat Developer Workshops and Demos.
The role can also be used to install and configure:
[*] Red Hat OpenShift Serverless both Serving and Eventing
[*] https://www.openshift.com/learn/topics/pipelines[Red Hat OpenShift Pipelines]
[*] https://www.openshift.com/learn/topics/service-mesh[Red Hat OpenShift Service Mesh]
[*] https://www.redhat.com/en/resources/amq-streams-datasheet[Red Hat AMQ Streams]
[*] https://www.redhat.com/en/technologies/management/advanced-cluster-management[Red Hat Advanced Cluster Management for Kubernetes]
[*] https://camel.apache.org/docs/#camel-k[Apache Camel-K]
[*] https://www.redhat.com/en/technologies/jboss-middleware/codeready-workspaces[Red Hat Code Ready Workspaces]
== Requirements
Python v3
https://www.docker.com/products/docker-desktop[Docker Desktop] or Docker for Linux
https://ansible.com[Ansible >= v2.9.10]
https://try.openshift.com[OpenShift 4.5+ Cluster]
[source,bash]
pip3 install
-r https://raw.githubusercontent.com/kameshsampath/ansible-role-openshift-spices/master/requirements.txt
ansible-galaxy role install -r https://raw.githubusercontent.com/kameshsampath/ansible-role-openshift-spices/master/requirements.yml
ansible-galaxy collection install -r https://raw.githubusercontent.com/kameshsampath/ansible-role-openshift-spices/master/requirements.yml
[NOTE]: For Windows its recommended to use Windows Subsystem for Linux (WSL)
== Role Variables
[%header,cols="1,2,1"] .Role Variables |=== | Variable Name| Description | Default value
| download_clients | Download OpenShift clients oc, kubectl and openshift-install | True
|ocp_bin_dir | Directory to download and install Openshift clients. The directory will be created if not exist | $HOME/openshift/bin
|ocp_version |The minimum OpenShift version to use |4.5.6
| deploy_serverless | Deploy OpenShift Serverless | True
| serverless_subcription_channel | The Operator Channel for the Serverless Subscription | 4.5
| knative_serving_cr | The Knative Serving Custom Resource | serverless/cr/serving.yaml
| knative_eventing_cr | The Knative Eventing Custom Resource | serverless/cr/eventing.yaml
| deploy_pipelines | Deploy OpenShift Pipelines | False
| deploy_argocd | Deploy Argo CD | False
| argocd_cr | The Argo CD Custom resource | argocd/cr.yaml
| argocd_release_channel | The Argo CD Release Channel | alpha
| deploy_acm | Deploy Advanced Cluster Management for Kubernetes(ACM) | False
| acm_cr | The ACM Custom resource | acm/cr.yaml
| acm_release_channel | The ACM Release Channel | release-2.0
| deploy_servicemesh | Deploy OpenShift Pipelines | False
| servicemesh_es_channel | The Operator Channel for the Red Hat Elastic Search Subscription | 4.5
| servicemesh_cr | The Red Hat Servicemesh Custom resource | servicemesh/cr.yaml
| servicemesh_members | Create and add projects Servicemesh a| [source,yaml]
servicemesh_members: create: False prefix: tutorial start: 0 end: 10
| deploy_kafka
| Deploy Apache Kafka using Strimzi
| False
| kakfa_cluster_name
| The Apache Kafka cluster name
| my-cluster
| kakfa_cluster_namespace | The Apache Kafka cluster namespace | kafka
| strimzi_kafka_cr | Apache Kafka Strimzi Custom Resource | kafka/cr.yaml
| knative_eventing_kafka_cr | Knative Eventing KafkaSource Custom Resource | kafka/eventing/cr.yaml
| deploy_camel_k | Deploy Apache Camel-K | False
| deploy_che | Deploy Eclipse Che | False
| eclipse_che_cr | The Eclipse Che Custom resource | che/cr.yaml
| deploy_acm | Deploy RedHat Advanced Cluster Management for Kubernetes | False
| users | Create OpenShift users and Cluster Administrator a| [source,yaml]
users: create: True prefix: user start: 0 end: 10 ocpadmin_username: ocpadmin
[NOTE]
Setting start and end to 0
will not create any users except cluster-admin
|===
== Example Playbooks
The https://github.com/kameshsampath/ansible-role-openshift-spices/tree/master/examples[examples] directory has various playbook examples to get started using this role:
e.g.
If you want to deploy OpenShift Serverless with Pipelines run:
[source,bash]
ansible-playbook examples/serverless_pipelines.yml
If you dont have Ansible installed locally, you can use the project https://github.com/kameshsampath/openshift-spice-runner[openshift-spice-runner] to runt he playbooks using Docker and https://ansible-runner.readthedocs.io/en/latest/[Ansible Runner].
== License
https://github.com/kameshsampath/ansible-role-openshift-spices/tree/master/LICENSE[Apache v2]
== Author Information
mailto:kamesh.sampath@hotmail.com[Kamesh Sampath]
== Issues
https://github.com/kameshsampath/ansible-role-openshift-spices/issues[Issues]
Setup OpenShift workshop cluster with required components
ansible-galaxy install kameshsampath/ansible-role-openshift-spices