Deploying your application on a target
You can deploy your application on one of three targets: Push-based deployment, Pull-based deployment, or a custom target.
Deploying using Push-based deployment
You can select Push based deployment
as the deployment target when you want to deploy your application on Red Hat® OpenShift® on IBM Cloud. DevSecOpsA methodology that integrates security practices with the software development and operations lifecycle. The goal of the merge is to prioritize the balance of development speed and security.
provides scripts to deploy your application on the cluster. You might need to customize these scripts according to your application and cluster requirements.
These scripts are located in the deployment repo and are specified in the pipeline-config.yml
file.
deploy:
image: icr.io/continuous-delivery/pipeline/pipeline-base-image:2.12@sha256:ff4053b0bca784d6d105fee1d008cfb20db206011453071e86b69ca3fde706a4
script: |
#!/usr/bin/env bash
if [[ "$PIPELINE_DEBUG" == 1 ]]; then
trap env EXIT
env
set -x
fi
source scripts/deploy_setup.sh
source scripts/deploy.sh
export DEPLOY_EXIT=$?
source scripts/doi-publish-deploy.sh
Deploying using Pull-based deployment
DevSecOps provides an option to deploy your application using Pull-based deployment using IBM Cloud Satellite Config.
IBM Cloud Satellite is an extension of the IBM Cloud Public that can run inside the customer's data center or out at the edge. Each IBM Cloud Satellite location is connected by using IBM Cloud Satellite Link, which provides the connection to the IBM Cloud® control plane. It provides audit, packet capture, and visibility to the security team, while a configuration utility provides a global view of applications and services. IBM Cloud Satellite Link provides a simple way to manage the connection between IBM Cloud and the Satellite location with visibility into all the traffic that goes back and forth with control of the endpoints on both sides of the link.
Users can have groups of Red Hat® OpenShift® clusters in a Satellite cluster group. You can use Satellite Config to deploy the application into a Satellite cluster group.
Follow a two-step process to enable your Red Hat® OpenShift® clusters to leverage Satellite Config to perform simultaneous deployments.
-
Create a cluster group, which is a logical grouping of clusters that run on a Satellite location.
-
Attach a cluster to a cluster group, which grants Satellite Config access to manage the resources within the cluster.
As an advanced configuration, you can also deploy the application to the compute infrastructure in your on-premises data center or other cloud providers by using IBM Cloud Satellite.
-
Create a Satellite location for the compute infrastructure in your on-premises data center or other cloud providers by using predefined templates.
-
Deploy a Red Hat® OpenShift® cluster to the Satellite location by using setup.
-
Create a cluster group, which is a logical grouping of clusters that run on a Satellite location.
-
Attach a cluster to a cluster group, which grants Satellite Config access to manage the resources within the cluster.
Prerequisites
- This toolchain uses Satellite Config to deploy an application to a group of clusters.
- This toolchain assumes that you have a Satellite cluster group with the required clusters.
- This toolchain supports a Satellite cluster group that contains only one type of cluster (Red Hat® OpenShift®).
Deployment
DevSecOps provides out of the box scripts to deploy your application on the group of clusters. You might need to customize these scripts according to your application and cluster group requirements.
These scripts are located in the deployment repository and are specified in the pipeline-config.yml
file.
deploy:
image: icr.io/continuous-delivery/pipeline/pipeline-base-image:2.12@sha256:ff4053b0bca784d6d105fee1d008cfb20db206011453071e86b69ca3fde706a4
script: |
#!/usr/bin/env bash
if [[ "$PIPELINE_DEBUG" == 1 ]]; then
trap env EXIT
env
set -x
fi
source scripts/deploy_setup.sh
source scripts/deploy.sh
export DEPLOY_EXIT=$?
source scripts/doi-publish-deploy.sh
Deploying to a custom target
Deploy to a custom target if you want to:
- Deploy your application on your own choice of infrastructure, such as Virtual Server Instances (VSI).
- Perform custom tasks, such as updating some configurations in a Red Hat® OpenShift® cluster.
In these cases, select "custom" as a deployment target.
Performing a custom deployment
- DevSecOps templates are fully customizable. You can provide your own stages and steps in the
pipeline-config.yml
file of the deployment repository. - You can provide your custom scripts in the
setup
,deploy
, andacceptance-test
stages in thepipeline-config.yml
file. - These scripts are run during the continuous deployment (CD) pipeline run.