# Red Hat Certified Spinnaker Operator

### Spinnaker Lifecycle Management <a href="#spinnaker-lifecycle-management" id="spinnaker-lifecycle-management"></a>

* In this document we are going to explore the Red Hat Certified Spinnaker Operator to install Red Hat Certified Spinnaker.
* There are several ways of using the Spinnaker Operator
  * OpenShift 4 Certified Operators Marketplace
  * Quay, as a Custom Operator
  * As a CRD, which omits Operator Lifecycle management
* The simplest approach by far is by using the OpenShift 4 Certified Operator Marketplace. When customization or other changes are desired, using the CRD or Quay might be a better fit.

### Using the OpenShift 4 Marketplace <a href="#using-the-openshift-4-marketplace" id="using-the-openshift-4-marketplace"></a>

* The marketplace requires a running OpenShift 4 installation, either use the openshift-installer, the disconnected install guide, or code ready containers. CRC is excellent for testing purposes and is thel most accessible option to work with for small test installs.

#### Instructions to use Marketplace Operator <a href="#instructions-to-use-marketplace-operator" id="instructions-to-use-marketplace-operator"></a>

* Log into OpenShift with an account that has privileges to install Operators, we’re using kubeadmin on our CRC install because it’s convenient, but would by no means advice anyone to do that on a production system.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK27r5l2CQCYhrQ2fj%2Fimage.png?alt=media\&token=d5f40ea6-248d-4ebb-973e-70a5b76a656e)

* Go to Operators, OperatoHub, and filter for spinnaker. *The community operator as well as the Open Enterprise Spinnaker Operator will show. The Open Enterprise Spinnaker Operator is the only Red Hat Certified Spinnaker, with all containers Red Hat Certified. Click on the Open Enterprise Spinnaker Operator.*

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2Bcc5VASXCG321y7%2Fimage.png?alt=media\&token=53c48432-fe98-492f-a659-c399b840b31f)

* The brings up the Operator Overview, with its documentation and the install button. Clicking the *install* button will bring up the *create subscription* page.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2EUn-l16b9UddKQQ%2Fimage.png?alt=media\&token=af03ff9c-76c6-4ffc-b835-ba718aebfd0f)

* The Create Operator Subscription is part of the [*Operator Lifecycle Manager*](https://github.com/operator-framework/operator-lifecycle-manager). The OLM framework enables the creator of an *operator* to update the Operator and offer new functionality, features, and versions to users without users having to lift a finger, when users decide to subscribe to the *Automatic Approval Strategy*.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2J3QNRnDXjmvgRqe%2Fimage.png?alt=media\&token=9edd9e4d-e5e9-4fde-9de0-d88c2270f4c9)

* After clicking *Subscribe*, the installation automatically redirects to the *Installed Operators* section, where the status will change with the progress made on installing the Operator. Installation takes a couple of seconds before the status changes to *InstallSucceeded as shown below*.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2REjZrxToZiyCc-_%2Fimage.png?alt=media\&token=087f1b52-d577-4a5c-bba7-8615d26aef88)

* Behind the scenes, the *Operator Framework* has set up the *OLM Subscription*, and the *Custom Resource Definition* backed by the *OES Operator*. The installation of the *OES Operator pre-creates a Deployment with a Pod* that can be used to trigger helm charts which deploy spinnaker based of a configurable *manifest*.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2Vg6WOgPO2q3ZmaM%2Fimage.png?alt=media\&token=7a5cca83-4539-4d23-8e21-305a5a1846b1)

* Going back to the *Installed Operators* and clicking the *Open Enterprise Spinnaker Operator* link will pull up the Operator Details page.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2_BIeRApEn-gMyqh%2Fimage.png?alt=media\&token=fb64bd7c-efb6-4942-9c1c-de61c5ad5838)

* To create a deployment of Spinnaker, select the *Open Enterprise Spinnaker Operator* tab and click the *Create Open Enterprise Spinnaker Operator* button.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2d3ud7DC2uo2nPe5%2Fimage.png?alt=media\&token=6d2ab39b-5fd5-40e2-a2a4-12d931bad7d8)

* The YAML on the screen is the actual configuration that gets fed to the *CRD’s API* endpoint, and gets translated to commands for *halyard*. The helm charts take care of the translation in the *spinnaker-operator pod* — the version of the spinnaker-operator container dictates which features are exposed from an operator perspective.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2jM3ts0W2FHza_2I%2Fimage.png?alt=media\&token=1f037943-529b-475f-a6d6-64d3877624e4)

* The default example presented does not expose spinnaker’s UI on a URL. To expose spinnaker’s UI, we can edit the configuration and add an *ingress*. When using OpenShift 4, the ingress class is *LoadBalancer*. It is also essential to set the *hostname* for the *ingress* correctly. In this example, the *host* should end in *apps-crc.testing*, as that is the cluster’s domain name. Below is a sample configuration that leverages the *ingress* for the UI and the API.

  ```
      apiVersion: charts.helm.k8s.io/v1alpha1
      kind: OpenEnterpriseSpinnakerOperator
      metadata:
      name: oes
      namespace: openshift-operators
      spec:
      halyard:
      spinnakerVersion: 1.15.1
      image:
      repository: registry.connect.redhat.com/opsmx/ubi8-oes-operator-halyard
      tag: 1.15.1-1
      dockerRegistries:
      - name: dockerhub
      address: index.docker.io
      repositories:
      - library/alpine
      - library/ubuntu
      - library/centos
      - library/nginx
      spinnakerFeatureFlags:
      - artifacts
      - jobs
      minio:
      enabled: true
      imageTag: RELEASE.2019-09-18T21-55-05Z
      serviceType: ClusterIP
      accessKey: spinnakeradmin
      secretKey: spinnakeradmin
      bucket: spinnaker
      nodeSelector: {}
      persistence:
      enabled: false
      rbac:
      create: true
      serviceAccount:
      create: true
      halyardName: open-enterprise-spinnaker
      spinnakerName: null
      ingress:
      enabled: true
      host: spinnaker.apps-crc.testing
      annotations:
      ingress.kubernetes.io/ssl-redirect: 'false'
      kubernetes.io/ingress.class: LoadBalancer
      ingressGate:
      enabled: true
      host: gate.spinnaker.apps-crc.testing
      annotations:
      ingress.kubernetes.io/ssl-redirect: 'false'
      kubernetes.io/ingress.class: LoadBalancer
  ```
* After adapting the configuration click the *create* button to deploy spinnaker. For other configuration options the [values.yaml](https://github.com/OpsMx/opsmx-spinnaker-operator/blob/rhel/helm-charts/open-enterprise-spinnaker/values.yaml) in the Github repository is leading.
* Creation of the deployment leads back to the *Operator Details*. Clicking the deployment’s name there brings up the *Operator Overview*, where the *Resources* tab shows the base components for the deployment.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2nTcknC6mqaBS5o3%2Fimage.png?alt=media\&token=77984469-d72c-4b37-8757-eef1f8aa3fa6)

* When deploying the Red Hat Certified Minio, and halyard containers they get pulled into OpenShift from the Red Hat registry. To follow halyard’s progress, the *Logs* tab in the *Pod Details* shows the execution flow of the supplied configuration, and subsequently, the creation of the services required for spinnaker. Following the halyard, logs are also possible from the CLI by using either *‘kubectl’* or *‘oc’* with *‘logs -f’* on the halyard Pod.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2qDCRtrhZsWV9R4X%2Fimage.png?alt=media\&token=bb6ae9cd-5c9e-4600-8fb6-18e637e3e30e)

* If the name serving for OpenShift has been set up correctly in the cluster, and externally, the URL provided in the configuration, [http://spinnaker.apps-crc.testing](http://spinnaker.apps-crc.testing/), should initially return an error that the application is not available.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2suTX_OOreSomMp9%2Fimage.png?alt=media\&token=325f5c4e-b2c6-4fda-8e72-e95b2f3dc6ab)

* As soon as several of the containers have spun up, which can be seen in the *Pods*, *Deployments*, or *Services* overview of the namespace, the frontend of Spinnaker becomes available. The initial “Hello!” screen loads and lands on Spinnaker’s search page.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2wSVaTaKjO6x0XOe%2Fimage.png?alt=media\&token=3f315763-6da4-4023-83de-50d595e510d2)

* Generally, Spinnaker Operator deployment process will take couple of minutes time, as some of the services might be configuring depending on the options and the system configuration.
* The search UI will be responsive, as long as the projects and the applications do not load the full stack is not yet done configuring and deploying.

![](https://2047464521-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MBEa1hoX6SqpDj-ymNs%2F-MGK22BWTJGspIezhEt-%2F-MGK2zhD1uJCtRUOujCr%2Fimage.png?alt=media\&token=d42e8396-85d7-453c-bdab-e37e7e86e722)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.opsmx.com/opsmx-context-graph-and-data-fabric/additional-resources/code-labs/red-hat-certified-spinnaker-operator.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
