Bug 1621291
| Summary: | Jenkins client plugin openshiftImageStream and openshiftVerifyService | ||
|---|---|---|---|
| Product: | OpenShift Container Platform | Reporter: | Robert Bost <rbost> |
| Component: | Build | Assignee: | Gabe Montero <gmontero> |
| Status: | CLOSED ERRATA | QA Contact: | XiuJuan Wang <xiuwang> |
| Severity: | low | Docs Contact: | |
| Priority: | low | ||
| Version: | 3.7.1 | CC: | aos-bugs, bparees |
| Target Milestone: | --- | ||
| Target Release: | 3.11.0 | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | No Doc Update | |
| Doc Text: |
undefined
|
Story Points: | --- |
| Clone Of: | Environment: | ||
| Last Closed: | 2018-10-11 07:25:25 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Robert Bost
2018-08-23 14:50:53 UTC
I have an `openshiftVerifyService` equivalent working and will update the README shortly. We are not implementing the ImageStream SCM equivalent in the client plugin at this time. I will update the README to note that as well. Ben - I think the imagestream SCM piece is in line with our prior conversations, but certainly chime in as you deem appropriate. > I think the imagestream SCM piece
not sure what the "imagestream SCM piece" would be in this context?
Ben reminded me: with the advent of OpenShift Pipeline Build Strategy, incorporating your pipeline into such a BuildConfig along with the use of an Image Change Trigger is the better choice for triggering pipeline jobs from changes to ImageStreams in OpenShift. The reason behind why we don't have an imagestream SCM in the new plugin. Will add some verbiage around that in the README update. Create a service named frontend.
Create a new pipeline item in jenkins console
Configure the pipeline job with code of equivalent of openshiftVerifyService
openshift.withCluster() {
openshift.withProject() {
def serviceSelector = openshift.selector("svc", "frontend")
def clusterIP = serviceSelector.object().spec.clusterIP
def port = serviceSelector.object().spec.ports[0].port
echo "cluster ip ${clusterIP} port ${port}"
env.SERVICE_URL = "http://" + clusterIP + ":" + port
// update the parameters to curl to deal with
// authentication to your service, or manage retry
// or timeouts, as needed
sh 'curl -s ${SERVICE_URL}'
}
}
The job build succeed with svc page returned.
openshift v3.11.0-0.28.0
kubernetes v1.11.0+d4cacc0
jenkins-2-rhel7:v3.11.0-0.28.0
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2018:2652 |