Clodbess CI - Openshift

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 4

Installing CloudBees CI on modern cloud

platforms on OpenShift
4 minute read

Credit: https://docs.cloudbees.com/docs/cloudbees-ci/latest/openshift-install-guide/installing-
openshift-using-helm

 Installing CloudBees CI on modern cloud platforms with HTTP support


 Installing CloudBees CI on modern cloud platforms with HTTPS support
 Verifying the installation using helm status
 Signing in to your CloudBees CI installation

Make sure to review the OpenShift pre-installation requirements before you install
CloudBees CI on modern cloud platforms. The supported Helm versions are listed in
the Supported platforms page.
Typically, controllers are provisioned using a full context path such as http://acme.com/controller1 and you
the operations center using a URL like http://acme.com/cjoc, for example. However, because you cannot reg
more than one URL using the same domain in OpenShift, it is not possible to deploy multiple controllers using t
same domain, for example, http://acme.com/controller1 and http://acme.com/controller2.
Therefore, for OpenShift CloudBees CI deployments, you can optionally configure subdomains to access contro
and the operations center. When you install CloudBees CI using the Helm chart, if you set the Subdomain attribu
to true, you configure CloudBees CI to use a subdomain instead of the typical full context path. So, for exampl
can access the operations center using http://cjoc.acme and the controllers
using http://controller1.acme.com and http://controller2.acme.com.
The following steps allow you to install CloudBees CI with either HTTP or HTTPS support.
Installing CloudBees CI with HTTP or HTTPS support does the following:
 Sets the OperationsCenter.HostName and optionally
the OperationsCenter.Name (the default value is cjoc) fields.
 Installs the Helm chart with the release name cloudbees-core and
hostname cloudbees-core.example.com.
 Deploys cloudbees-core on the OpenShift cluster in the default configuration.
CloudBees CI on modern cloud platforms uses Docker containers to run a cluster of computers within OpenShif
can optionally Verify the CloudBees CI on modern cloud platforms Docker images to ensure their origin and
authenticity.
Refer to one of the following procedures to install CloudBees CI on modern cloud
platforms:
 Installing CloudBees CI on modern cloud platforms with HTTP support .
 Installing CloudBees CI on modern cloud platforms with HTTPS support .
Installing CloudBees CI on modern cloud platforms with
HTTP support
To install CloudBees CI on modern cloud platforms with HTTP support:
1. Type the following commands:
Fields are case-sensitve: OperationsCenter.HostName is different than operationscenter.hostname.

$ helm install cloudbees-core \


cloudbees/cloudbees-core \
--set OperationsCenter.HostName='cloudbees-core.example.com' \
If you copy this command into your terminal don’t forget to remove the annotations at the end of
each line.

The name isn’t required, but without it Helm will automatically generate a release name with
random strings. For this reason, CloudBees recommends always set a release name.

In this example, the command is using the CloudBees Helm chart repository. If you downloaded the
CloudBees CI Helm chart using helm fetch, replace cloudbees/cloudbees-core with the file
name.

OperationsCenter.HostName field is required. The CloudBees CI Helm chart will not install
without a HostName being provided.

After you have installed CloudBees CI, you should verify that it is installed correctly.
Installing CloudBees CI on modern cloud platforms with
HTTPS support
To install CloudBees CI on modern cloud platforms with HTTPS support:
1. First, create a new OpenShift TLS certificate secret. For instructions, see
the Secrets chapter of the Red Hat OpenShift documentation.
2. Once an OpenShift certificate secret has been created, you can use the Helm
chart to install CloudBees CI with SSL\TLS support by
setting OperationsCenter.Ingress.tls.Enable to true.
3. Type the following commands:
Fields are case-sensitve: OperationsCenter.HostName is different than operationscenter.hostname.

$ helm install cloudbees-core \


cloudbees/cloudbees-core \
--set OperationsCenter.HostName='{domain-name}'
--set OperationsCenter.Route.tls.Enable=true \
Here, you are setting OperationsCenter.Route.tls.Enable to true. This property turns on
CloudBees CI HTTPS support.

After you have installed CloudBees CI, you should verify that it is installed correctly.
Verifying the installation using helm status
Once the CloudBees CI install is initiated, Helm displays the status of the release.
The helm status command displays the status of the CloudBees CI release. This
command is also executed after helm install and helm update commands are executed.
The helm status command displays three areas of information:
 Current CloudBees CI Release
 Kubernetes Resources
 Release Notes
$ helm status
NAME: cloudbees-core
LAST DEPLOYED: Tue Apr 16 17:44:12 2019
NAMESPACE: default
STATUS: DEPLOYED
REVISION: 1
TEST SUITE: None
NOTES:
1. Once {OC} is up and running, get your initial admin user password by running:
kubectl rollout status sts cjoc --namespace cloudbees-core
kubectl exec cjoc-0 --namespace cloudbees-core -- cat
/var/jenkins_home/secrets/initialAdminPassword
2. Visit https://acme.example.com/cjoc/

3. Login with the password from step 1.

For more information on running {CI-CLOUD}, visit:


xref:cloudbees-ci:ROOT:index.adoc[CloudBees CI]

The first block provides a summary of the CloudBees CI release including:

 Name of the release


 The time released
 The status of the release and
 The namespace the release is installed in.
Signing in to your CloudBees CI installation
Now that you’ve installed CloudBees CI and operations center, you’ll want to see your
system in action.
1. Retrieve your administrative user password with the oc command:
$ oc exec cjoc-0 -- cat /var/jenkins_home/secrets/initialAdminPassword
2. Open a browser client and navigate
to http://cloudbees-core.example.com/cjoc/ .
3. Sign in with the username admin and the password you retrieved.
If you use the OpenShift Jenkins plugin, you can now configure it to work with CloudBees CI on modern cloud platforms.
Red Hat’s OpenShift Jenkins plugin documentation for more information.

Pre-installation requirements

Verifying Docker images

Submit Feedback

© CloudBees, Inc. 2010 - 2024

Privacy Policy|Legal Notices|Security

You might also like