OpenShift CI/CD Operations: Difference between revisions
Jump to navigation
Jump to search
Line 11: | Line 11: | ||
{{Internal|OpenShift Set Up a Standalone, cicd-template.yaml-Based Jenkins|Set Up a Standalone, cicd-template.yaml-Based Jenkins}} | {{Internal|OpenShift Set Up a Standalone, cicd-template.yaml-Based Jenkins|Set Up a Standalone, cicd-template.yaml-Based Jenkins}} | ||
=Checkpoint= | =Checkpoint= |
Revision as of 02:42, 22 November 2017
Internal
Overview
Set Up a CI/CD Pipeline
Checkpoint
- Jenkins should start and be available at https://jenkins-cicd.apps.openshift.novaordis.io/
- Gogs should start and be available at https://gogs-cicd.apps.openshift.novaordis.io/
- Nexus should start and be available at https://nexus-cicd.apps.openshift.novaordis.io/
Configure the Jenkins Pipeline
New Item -> "hello-nodejs-pipeline" -> Pipeline -> OK
Pipeline -> Definition -> Pipeline script:
node {
stage ("Build") {
echo '*** Build Starting ***'
openshiftBuild apiURL: 'https://openshift.default.svc.cluster.local', authToken: '', bldCfg: 'hello-nodejs', buildName: '', checkForTriggeredDeployments: 'false', commitID: '', namespace: '', showBuildLogs: 'false', verbose: 'false', waitTime: ''
openshiftVerifyBuild apiURL: 'https://openshift.default.svc.cluster.local', authToken: '', bldCfg: 'hello-nodejs', checkForTriggeredDeployments: 'false', namespace: '', verbose: 'false'
echo '*** Build Complete ***'
}
stage ("Deploy") {
echo '*** Deployment Starting ***'
openshiftDeploy apiURL: 'https://openshift.default.svc.cluster.local', authToken: '', depCfg: 'hello-nodejs', namespace: '', verbose: 'false', waitTime: ''
openshiftVerifyDeployment apiURL: 'https://openshift.default.svc.cluster.local', authToken: '', depCfg: 'hello-nodejs', namespace: '', replicaCount: '1', verbose: 'false', verifyReplicaCount: 'false', waitTime: ''
echo '*** Deployment Complete ***'
}
stage ("Verify") {
echo '*** Service Verification Starting ***'
openshiftVerifyService apiURL: 'https://openshift.default.svc.cluster.local', authToken: '', namespace: '', svcName: 'hello-nodejs', verbose: 'false'
echo '*** Service Verification Complete ***'
}
}