openshift / pipelines-tutorial Goto Github PK
View Code? Open in Web Editor NEWA step-by-step tutorial showing OpenShift Pipelines
License: Apache License 2.0
A step-by-step tutorial showing OpenShift Pipelines
License: Apache License 2.0
I set up the tutorial pipeline on OCP 4.2 using the provided instructions. Afterwards, the pipeline looks as expected, with all checks returning the expected results.
When I run the pipline though, the run fails, because a PVC cannot be bound to a PV:
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: petclinic-deploy-pipeline-run-nl62q-pvc
namespace: pipelines-tutorial
selfLink: >-
/api/v1/namespaces/pipelines-tutorial/persistentvolumeclaims/petclinic-deploy-pipeline-run-nl62q-pvc
uid: 41bae36f-104a-11ea-8e86-00000a10063b
resourceVersion: '5774327'
creationTimestamp: '2019-11-26T12:42:50Z'
ownerReferences:
- apiVersion: tekton.dev/v1alpha1
kind: PipelineRun
name: petclinic-deploy-pipeline-run-nl62q
uid: 41b42f70-104a-11ea-b7cb-00000a10063a
controller: true
blockOwnerDeletion: true
finalizers:
- kubernetes.io/pvc-protection
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 5Gi
volumeMode: Filesystem
status:
phase: Pending
Error event:
PVCpetclinic-deploy-pipeline-run-nl62q-pvc
NamespaceNSpipelines-tutorial
Nov 26, 1:47 pm
Generated from persistentvolume-controller
19 times in the last 4 minutes
no persistent volumes available for this claim and no storage class is set
I created a PV beforehand to service the PVC bind (no storageClass, volume mode Filesystem), but it doesn't get used:
kind: PersistentVolume
apiVersion: v1
metadata:
name: pipeline-storage
selfLink: /api/v1/persistentvolumes/pipeline-storage
uid: 02156811-102a-11ea-b7cb-00000a10063a
resourceVersion: '5772668'
creationTimestamp: '2019-11-26T08:51:59Z'
finalizers:
- kubernetes.io/pv-protection
spec:
capacity:
storage: 5Gi
nfs:
server: 10.16.4.176
path: /data
accessModes:
- ReadWriteMany
persistentVolumeReclaimPolicy: Recycle
volumeMode: Filesystem
status:
phase: Available
How can I get this resolved?
Following the demo on IBM Cloud ROKS. Not sure where to go. Are there logs that could provide more detail?
[f*****@localhost ~]$ tkn pipeline start build-and-deploy
-w name=shared-workspace,volumeClaimTemplateFile=https://raw.githubusercontent.com/openshift/pipelines-tutorial/master/01_pipeline/03_persistent_volume_claim.yaml
-p deployment-name=vote-api
-p git-url=http://github.com/openshift-pipelines/vote-api.git
-p IMAGE=image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/vote-api \Error: admission webhook "webhook.pipeline.tekton.dev" denied the request: mutation failed: cannot decode incoming new object: json: unknown field "volumeClaimTemplate"`
OpenShift version 4.4.20
tkn version
Client version: 0.11.0
Pipeline version: v0.11.3
Triggers version: v0.4.0
oc version
Client Version: 4.5.0-202005291417-9933eb9
Server Version: 4.4.20
Kubernetes Version: v1.17.1+6af3663
Hi
I am following this tutorial with CRC openshift 4.5 cluster. I used the web console to installed openshift pipeline via OpenShift OperatorHub. When I try to create anything regarding manifest, tasks, pipelinereosurce, etc, I get the following error:
Error from server (BadRequest): error when creating "/home/ybello/PycharmProjects/sdp-pipeline/01_apply_manifest_task.yaml": admission webhook "webhook.tekton.dev" denied the request: mutation failed: cannot decode incoming new object: json: unknown field "managedFields"
Any suggestion will be appreciated, thank you.
OCP Version: 4.6.12
Openshift Pipelines Version: 1.2.3
Tekton Pipelines: v0.16.3
Tekton Triggers: v0.8.1
ClusterTasks based on Tekton Catalog 0.16
I followed the tutorial step by step. After creation of the "Event Listener" an Error on the WebUI occoured.
Clicking on the menu "Pipelines" as well as the menu "Triggers" raise the problem repeatably. The WebUI completely blanks when using the mentioned menus.
Error in developer console:
vendorsmain-chunk-097f186a6bd6062a5833.min.js:159202 TypeError: Cannot read property 'name' of undefinedadmin-tasks
at admin-pipeline~pipeline-builder-edit-page~pipeline-builder-page~pipeline-details~pipeli~8d3f0553-chunk-108e39123867785f9969.min.js:1 at Array.map (<anonymous>) at b (admin-pipeline~admin-tasks
pipeline-builder-edit-pagepipeline-builder-pagepipeline-detailspipeli8d3f0553-chunk-108e39123867785f9969.min.js:1)admin-tasks
at Array.map ()
at admin-pipeline~pipeline-builder-edit-page~pipeline-builder-page~pipeline-details~pipeli~8d3f0553-chunk-108e39123867785f9969.min.js:1 at Object.useMemo (vendors~main-chunk-097f186a6bd6062a5833.min.js:159202) at Object.useMemo (vendors~main-chunk-097f186a6bd6062a5833.min.js:159167) at v (admin-pipeline~admin-tasks
pipeline-builder-edit-pagepipeline-builder-pagepipeline-detailspipeli8d3f0553-chunk-108e39123867785f9969.min.js:1)main-chunk-097f186a6bd6062a5833.min.js:159202)
at a.a (admin-pipeline-chunk-ba2b32ed7673e4d4b4f6.min.js:1)
at No (vendors
Following the tutorial and at the point where I execute:
tkn pipeline start build-and-deploy \
-w name=shared-workspace,volumeClaimTemplateFile=https://raw.githubusercontent.com/openshift/pipelines-tutorial/master/01_pipeline/03_persistent_volume_claim.yaml \
-p deployment-name=vote-api \
-p git-url=http://github.com/openshift-pipelines/vote-api.git \
-p IMAGE=image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/vote-api \
There is an error:
Error: invalid input format for workspace : name=shared-workspace,volumeClaimTemplateFile=https://raw.githubusercontent.com/openshift/pipelines-tutorial/master/01_pipeline/03_persistent_volume_claim.yaml
I can read the URL 03_persistent_volume_claim.yaml
$ oc version
Client Version: 4.4.0-202005290638-1960dd7
Server Version: 4.4.20
Kubernetes Version: v1.17.1+6af3663
$ tkn version
Client version: 0.9.0
Pipeline version: v0.11.3
It would be nice to have an example that uses a Deployment instead of a DeploymentConfig. The openshift 4.x documentation states:
It is recommended to use Deployments unless you need a specific feature or behavior provided by DeploymentConfigs footnote:[https://docs.openshift.com/container-platform/4.2/applications/deployments/what-deployments-are.html]. Deployments do not support (yet) automatically rolling back to the last successfully deployed ReplicaSet in case of a failure.
Does openshift pipelines requires the usage of DeploymentConfig ?
When running the tutorial, I'm getting this error in v0.10.7:
`
tkn pr describe build-and-deploy-ex8xsq
Name: build-and-deploy-ex8xsq
Namespace: pipelines-tutorial
Pipeline Ref: build-and-deploy
Service Account: pipeline
Timeout: 1h0m0s
Labels:
tekton.dev/pipeline=build-and-deploy
Status
STARTED DURATION STATUS
3 minutes ago 0 seconds Failed(PipelineValidationFailed)
Message
invalid input resources: TaskRun's declared resources didn't match usage in Task: [source]
`
When I run the pipeline along with the instruction, I got this error.
I0727 21:54:00.303203 11 request.go:621] Throttling request took 1.186453224s, request: GET:https://172.30.0.1:443/apis/snapshot.storage.k8s.io/v1beta1?timeout=32s
Error from server (NotFound): deployments.apps "vote-ui" not found
I created the resources as below but I can't find where the pipeline refers to "vote-ui" as deployment.apps resource.
$ tkn resource list
NAME TYPE DETAILS
api-repo git url: http://github.com/openshift-pipelines/vote-api.git
ui-repo git url: http://github.com/openshift-pipelines/vote-ui.git
api-image image url: image-registry.openshift-image-registry.svc:5000/user1-cloudnative-pipeline/vote-api:latest
ui-image image url: image-registry.openshift-image-registry.svc:5000/user1-cloudnative-pipeline/vote-ui:latest
When I try to run the tutorial on an OCP 4 cluster I can reach the point where I create the pipeline but there are no resources in this YAML:
https://raw.githubusercontent.com/openshift/pipelines-tutorial/master/01_pipeline/04_pipeline.yaml
and I don't get any output when I try:
tkn resource ls.
When I try to run the pipeline using
tkn pipeline start build-and-deploy \
-w name=shared-workspace,claimName=source-pvc \
-p deployment-name=vote-api \
-p git-url=http://github.com/openshift-pipelines/vote-api.git \
-p IMAGE=image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/vote-api
The run fails with the following error:
invalid input params: didn't need these params but they were provided anyway: [IMAGE]
Removing the -p IMAGE parameter still results in that error.
Thanks,
Atef
The images in the install-operator.md file are missing. For example:
https://github.com/openshift/pipelines-tutorial/blob/master/images/administrator.png
While creating an openshift-client task, it failed with the message:
[core@master-0 ~]$ curl -O https://raw.githubusercontent.com/tektoncd/catalog/master/openshift-client/openshift-client-task.yaml
[core@master-0 ~]$ oc create -f openshift-client-task.yaml
Error from server (InternalError): error when creating "openshift-client-task.yaml": Internal error occurred: admission webhook "webhook.tekton.dev" denied the request: mutation failed: cannot decode incoming new object: json: cannot unmarshal array into Go struct field ParamSpec.default of type string
However, I was able to create the s2i-java-8-task in the same way.
Version: OpenShift v4.1.14
The instructions for deploying the app is not sufficiently clear:
You can also deploy the same applications by applying the artifacts available in k8s directory of the respective repo
It should provide the commands as well on how to deploy the apps with oc apply -f ...
OpenShift Version
4.3.1
Installed
openshift-pipelines-operator.v0.10.7
on ibm cloud
when I follow this example
pipeline-tutorial
after started the pipeline run, when I try to get the logs
`[build-ui : build] STEP 2: LABEL "io.openshift.s2i.build.image"="registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location"="."
[build-ui : build] error building at STEP "LABEL "io.openshift.s2i.build.image" "registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location" "."": error ensuring container path "/opt/app-root/src": lstat /var/lib/containers/storage/overlay/262cf5f36861100bf27c9eb5f9baa42f2471984ee129a5f1dd901d81cf3d4cbd/merged/opt: invalid argument
failed to get logs for task build-ui : container step-build has failed : [{"name":"","digest":"","key":"StartedAt","value":"2020-03-18T05:00:49Z","resourceRef":{}}]`
the detail logs:
`tkn pipelinerun logs build-and-deploy-run-wcp2z -f -n pipelines-tutorial
(base) Qianyangs-MBP:kevin-openshift-v4 qianyangyu$ tkn pipeline list
NAME AGE LAST RUN STARTED DURATION STATUS
build-and-deploy 18 minutes ago build-and-deploy-run-wcp2z 1 minute ago --- Running
(base) Qianyangs-MBP:kevin-openshift-v4 qianyangyu$ tkn pipeline logs -f
....
[build-api : git-source-api-repo-zjvxx] {"level":"info","ts":1584507618.453761,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-api : git-source-api-repo-zjvxx] {"level":"info","ts":1584507646.4758844,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-api : git-source-api-repo-zjvxx] {"level":"info","ts":1584507648.5243325,"logger":"fallback-logger","caller":"git/git.go:102","msg":"Successfully cloned http://github.com/openshift-pipelines/vote-api.git @ master in path /workspace/source"}
[build-api : git-source-api-repo-zjvxx] {"level":"warn","ts":1584507648.5244727,"logger":"fallback-logger","caller":"git/git.go:149","msg":"Unexpected error: creating symlink: symlink /tekton/home/.ssh /root/.ssh: file exists"}
[build-api : git-source-api-repo-zjvxx] {"level":"info","ts":1584507648.6062376,"logger":"fallback-logger","caller":"git/git.go:130","msg":"Successfully initialized and updated submodules in path /workspace/source"}
[build-ui : generate] {"level":"info","ts":1584507622.4569638,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-ui : generate] Application dockerfile generated in /gen-source/Dockerfile.gen
[build-api : build] {"level":"info","ts":1584507632.1757002,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-api : build] STEP 1: FROM golang:alpine AS builder
[build-api : build] Getting image source signatures
[build-api : build] Copying blob sha256:d909eff282003e2d64af08633f4ae58f8cab4efc0a83b86579b4bbcb0ac90956
[build-api : build] Copying blob sha256:cbb0d8da1b304e1b4f86e0a2fb11185850170e41986ce261dc30ac043c6a4e55
[build-api : build] Copying blob sha256:a50ef8b76e536c1f848f61399fe1e8721531496a1a3501124e2b24f4677f0cd0
[build-api : build] Copying blob sha256:c9b1b535fdd91a9855fb7f82348177e5f019329a58c53c47272962dd60f71fc9
[build-api : build] Copying blob sha256:8b9d9d6824f5457e80af26521acf1c1e52493e7a72889d778eb9bcc5f7eb68c4
[build-api : build] Copying config sha256:51e47ee4db586c983e61a925bea3b7b08f2d7b95718e3bd3fac3da97c1c6325f
[build-api : build] Writing manifest to image destination
[build-api : build] Storing signatures
[build-api : build] STEP 2: WORKDIR /build
[build-api : build] 4b4d17ba12c7cfe122a9b3ed8a5a3687a280d6761547aee55586251584af5321
[build-api : build] STEP 3: ADD . /build/
[build-api : build] 2cb4b995b852e4f1aa3a2fa736d64ad88c8c6b668c53a9b5903f70cf9bf45ce2
[build-api : build] STEP 4: RUN GOOS=linux GARCH=amd64 CGO_ENABLED=0 go build -mod=vendor -o api-server .
[build-ui : build] {"level":"info","ts":1584507640.7401912,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-ui : build] STEP 1: FROM registry.access.redhat.com/rhscl/python-36-rhel7
[build-ui : build] Getting image source signatures
[build-ui : build] Copying blob sha256:6a4fa4bc2d06e942c0e92d69614b4ee30c2d409c95f29a3a22ece8087ce164be
[build-ui : build] Copying blob sha256:455ea8ab06218495bbbcb14b750a0d644897b24f8c5dcf9e8698e27882583412
[build-ui : build] Copying blob sha256:bb13d92caffa705f32b8a7f9f661e07ddede310c6ccfa78fb53a49539740e29b
[build-ui : build] Copying blob sha256:c8106f599d69375cbfc2ef44b11812ddc33938ab1e94860b02c262118f837611
[build-ui : build] Copying blob sha256:84e620d0abe585d05a7bed55144af0bc5efe083aed05eac1e88922034ddf1ed2
[build-ui : build] Copying config sha256:3c93c53ba3715f62aad12366410a1cd57957c39f573c0681807000d12f3cccdc
[build-ui : build] Writing manifest to image destination
[build-ui : build] Storing signatures
[build-ui : build] STEP 2: LABEL "io.openshift.s2i.build.image"="registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location"="."
[build-ui : build] error building at STEP "LABEL "io.openshift.s2i.build.image" "registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location" "."": error ensuring container path "/opt/app-root/src": lstat /var/lib/containers/storage/overlay/262cf5f36861100bf27c9eb5f9baa42f2471984ee129a5f1dd901d81cf3d4cbd/merged/opt: invalid argument
failed to get logs for task build-ui : container step-build has failed : [{"name":"","digest":"","key":"StartedAt","value":"2020-03-18T05:00:49Z","resourceRef":{}}]
[build-api : build] f72f609911547c6bf2364e63cf786987cd7189c74d787d585d659284b7feba77
[build-api : build] STEP 5: FROM scratch
[build-api : build] STEP 6: WORKDIR /app
`
a related issue
Using OCP 4.4.3 When running the tutorial, I'm getting this error in v0.10.7:
oc create -f 04_pipeline.yaml
error: unable to recognize "04_pipeline.yaml": no matches for kind "Pipeline" in version "tekton.dev/v1beta1"
the reason is the version of the API is v1beta1 but the operator is using/expecting v1alpha1
in the other hand if i do the same for the apply-mainfests it would error :
Error from server (BadRequest): error when creating "01_apply_manifest_task.yaml": admission webhook "webhook.tekton.dev" denied the request: mutation failed: cannot decode incoming new object: json: unknown field "params"
this time is because the schema has changed between alpha and beta. please make sure all yamls are using the same version and running with latest Pipline operator (at the moment is v0.10.7)
Hi,
I'm using Openshift 4.5.11.
After creating the pipeline successfully I switched to the "Developer" Console to take a look into the "Topolopgy View" to figure that both Images image/apps have been deployed - but I see only the "API". It' did not create the frontend App with the route.
I can re-run the the pipeline with "tkn pipeline start build-and-deploy --last" over and over with out any errors but yet, no route/front end app.
Any Idea?
Thanks!
While going through this tutorial today on OpenShift 4.1.3 and the OpenShift Pipelines Operator v0.4.0, I get the error The server doesn't have a resource type "kind: PipelineResource, apiVersion: tekton.dev/v1alpha1".
when trying to create the PipelineResources. Maybe I am doing something wrong, but I cannot see what
Need to maintain tutorial per release. For instance, a Task
definition referred to in the tutorial should point to the compatible one from the catalog.
When following this tutorial with the crc-macos-1.0.0-beta.5 local install of openshift, I end up with this: https://gist.github.com/brujoand/72a564d1cd7d89586a7df181753457f4 which is the output log with the mvn download lines grepped out.
I can't really tell what the problem is. But this looks problematic:
[build : image-digest-exporter-generate-j8j8x] 2019/09/30 12:19:12 ImageResource petclinic-image doesn't have an index.json file: stat /builder/home/image-outputs/image/index.json: no such file or directory
Also this one at the end:
[deploy : oc] Error: unknown command "$(inputs.params.ARGS)" for "oc"
Any pointers on how to debug this?
After running the steps in this tutorial using an RHPDS 4.1 cluster, I triggered a pipeline after creating the git and image PipelineResources
by running oc create -f petclinic-deploy-pipelinerun.yaml
with the following:
apiVersion: tekton.dev/v1alpha1
kind: PipelineRun
metadata:
generateName: petclinic-deploy-pipelinerun-
spec:
pipelineRef:
name: deploy-pipeline
trigger:
type: manual
serviceAccount: 'pipeline'
resources:
- name: app-git
resourceRef:
name: petclinic-git
- name: app-image
resourceRef:
name: petclinic-image
After running tkn pr ls
I get:
NAME STARTED DURATION STATUS
petclinic-deploy-pipelinerun-4pqkp 15 minutes ago 1 second Failed
I then looked through the events on my cluster and found the following error message:
Missing or invalid Task pipelines-tutorial/s2i-java-8: pods
"petclinic-deploy-pipelinerun-qwq6k-build-hnq2g-pod-f9e7df" is
forbidden: [minimum memory usage per Container is 6Mi, but request is
0., minimum memory usage per Container is 6Mi, but request is 0.,
minimum memory usage per Container is 6Mi, but request is 0., minimum
memory usage per Container is 6Mi, but request is 0., minimum memory
usage per Container is 6Mi, but request is 0., minimum memory usage per
Container is 6Mi, but request is 0., minimum memory usage per Container
is 6Mi, but request is 0.]
Running tkn task ls -n pipelines-tutorial
shows that s2i-java-8
was added:
NAME AGE
openshift-client 1 hour ago
s2i-java-8 1 hour ago
There isn't much info in the logs, but below is all I was able to find when looking through the pipelinerun
yaml.
build-and-deploy-run-kw27h-update-deployment-2nnxc:
pipelineTaskName: update-deployment
status:
conditions:
- lastTransitionTime: '2020-10-02T18:53:52Z'
message: >-
bound workspaces did not match declared workspaces: provided extra
values: [source]
reason: TaskRunValidationFailed
status: 'False'
type: Succeeded
podName: ''
startTime: '2020-10-02T18:53:52Z'
I followed the pipelines tutorial on the openshift docs exactly, but I'm still running into this error.
Below is the command I'm running to start the pipelinerun
, as written in the docs:
tkn pipeline start build-and-deploy -w name=shared-workspace,claimName=source-pvc -p deployment-name=vote-api -p git-url=http://github.com/openshift-pipelines/vote-api.git -p IMAGE=image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/vote-api
Any help would be appreciated. Thanks!
I am trying this tutorial, step by step, I did it all, my problem is that my project have a diferent namespace and not "pipelines-tutorial", I don't want to use this name, because I am already using this for a real project. I did change it when I added the PipelineRun:
image-registry.openshift-image-registry.svc:5000/<namespace-name>/vote-api:latest
and all the other steps run well. The problem is when I commit changes and try it to build it, it throws me this error:
what I can see here is that is using image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/vote-api:latest
instead of my real namespace project, and already change it in all my other yaml files, I also checked the Dockerfile in both project (Vote-ui and Vote-api) and there is not pipelines-tutorial anywhere.
I also have this:
it is using the default pipelines-tutorial by default even if I changed it all. Maybe is there a place I forgot? I am very beginner with CD/CI, Docker.
Can you help me with this?
Pipeline should rebuild with changes
Pipeline errors with DockerFile not found
When the user starts the pipeline, the image is built and application is deployed. However, when the pipeline is started second time, the image is built but the old version continues to work.
The reason is that the tasks apply-manifests
and update-deployment
don't change anything (they replace the string with the same string) and therefore the deployment doesn't notice the change, see https://kubernetes.io/docs/concepts/workloads/controllers/deployment/
Note: A Deployment’s rollout is triggered if and only if the Deployment’s Pod template (that is, .spec.template) is changed, for example if the labels or container images of the template are updated. Other updates, such as scaling the Deployment, do not trigger a rollout.
there are multiple ways how to solve it:
Deployment
with DeploymentConfig
which is able to trigger rollout on change in image streamlatest
tag but e.g. timestamplatest
@vdemeester suggested the following
in the future we should use result instead of image PipelineResource, and have a step in those build that know how to get the digest
The fastest and easiest change is to use DeploymentConfig
instead of Deployment
.
The Link provided to install Tekton CLI is not Found.
Alternative tools such as CloudBees have a central operations manager that controls where to schedule builds. As an on-premise cluster reaches capacity the operations manager is able to target builds to an alternative on a scale public cloud cluster. While Tekton tasks can be directed to a specific target, is there a way to have the target be controlled by the build queue depth, cluster capacity, etc?
Is there a concept of build#? I would like to append that number as the last digit of version number (1.0.0.Build#
). This version number string is then used to dynamically build a PipelineResource
which is used as input in the next Task
, to build and push the container image, for instance. How is this achieved? Thanks.
Hello,
We are betting the following error when trying to pull from our private git repository
{"level":"error","ts":1587756144.758596,"logger":"fallback-logger","caller":"git/git.go:41","msg":"Error running git [fetch --recurse-submodules=yes --depth=1 origin master]: exit status 128\nfatal: unable to access 'https://gitlab.company.com/machine-shop/insight.git/': Peer's Certificate issuer is not recognized.\n","stacktrace":"github.com/tektoncd/pipeline/pkg/git.run\n\t/go/src/github.com/tektoncd/pipeline/pkg/git/git.go:41\ngithub.com/tektoncd/pipeline/pkg/git.Fetch\n\t/go/src/github.com/tektoncd/pipeline/pkg/git/git.go:90\nmain.main\n\t/go/src/github.com/tektoncd/pipeline/cmd/git-init/main.go:51\nruntime.main\n\t/usr/local/go/src/runtime/proc.go:203"}
OpenShift Version
4.3.1
Installed
openshift-pipelines-operator.v0.10.7
on ibm cloud
when I follow this example
pipeline-tutorial
after started the pipeline run, when I try to get the logs
[build-ui : build] STEP 2: LABEL "io.openshift.s2i.build.image"="registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location"="."
[build-ui : build] error building at STEP "LABEL "io.openshift.s2i.build.image" "registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location" "."": error ensuring container path "/opt/app-root/src": lstat /var/lib/containers/storage/overlay/262cf5f36861100bf27c9eb5f9baa42f2471984ee129a5f1dd901d81cf3d4cbd/merged/opt: invalid argument
failed to get logs for task build-ui : container step-build has failed : [{"name":"","digest":"","key":"StartedAt","value":"2020-03-18T05:00:49Z","resourceRef":{}}]`
the detail logs:
`tkn pipelinerun logs build-and-deploy-run-wcp2z -f -n pipelines-tutorial
(base) Qianyangs-MBP:kevin-openshift-v4 qianyangyu$ tkn pipeline list
NAME AGE LAST RUN STARTED DURATION STATUS
build-and-deploy 18 minutes ago build-and-deploy-run-wcp2z 1 minute ago --- Running
(base) Qianyangs-MBP:kevin-openshift-v4 qianyangyu$ tkn pipeline logs -f
....
[build-api : git-source-api-repo-zjvxx] {"level":"info","ts":1584507618.453761,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-api : git-source-api-repo-zjvxx] {"level":"info","ts":1584507646.4758844,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-api : git-source-api-repo-zjvxx] {"level":"info","ts":1584507648.5243325,"logger":"fallback-logger","caller":"git/git.go:102","msg":"Successfully cloned http://github.com/openshift-pipelines/vote-api.git @ master in path /workspace/source"}
[build-api : git-source-api-repo-zjvxx] {"level":"warn","ts":1584507648.5244727,"logger":"fallback-logger","caller":"git/git.go:149","msg":"Unexpected error: creating symlink: symlink /tekton/home/.ssh /root/.ssh: file exists"}
[build-api : git-source-api-repo-zjvxx] {"level":"info","ts":1584507648.6062376,"logger":"fallback-logger","caller":"git/git.go:130","msg":"Successfully initialized and updated submodules in path /workspace/source"}
[build-ui : generate] {"level":"info","ts":1584507622.4569638,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-ui : generate] Application dockerfile generated in /gen-source/Dockerfile.gen
[build-api : build] {"level":"info","ts":1584507632.1757002,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-api : build] STEP 1: FROM golang:alpine AS builder
[build-api : build] Getting image source signatures
[build-api : build] Copying blob sha256:d909eff282003e2d64af08633f4ae58f8cab4efc0a83b86579b4bbcb0ac90956
[build-api : build] Copying blob sha256:cbb0d8da1b304e1b4f86e0a2fb11185850170e41986ce261dc30ac043c6a4e55
[build-api : build] Copying blob sha256:a50ef8b76e536c1f848f61399fe1e8721531496a1a3501124e2b24f4677f0cd0
[build-api : build] Copying blob sha256:c9b1b535fdd91a9855fb7f82348177e5f019329a58c53c47272962dd60f71fc9
[build-api : build] Copying blob sha256:8b9d9d6824f5457e80af26521acf1c1e52493e7a72889d778eb9bcc5f7eb68c4
[build-api : build] Copying config sha256:51e47ee4db586c983e61a925bea3b7b08f2d7b95718e3bd3fac3da97c1c6325f
[build-api : build] Writing manifest to image destination
[build-api : build] Storing signatures
[build-api : build] STEP 2: WORKDIR /build
[build-api : build] 4b4d17ba12c7cfe122a9b3ed8a5a3687a280d6761547aee55586251584af5321
[build-api : build] STEP 3: ADD . /build/
[build-api : build] 2cb4b995b852e4f1aa3a2fa736d64ad88c8c6b668c53a9b5903f70cf9bf45ce2
[build-api : build] STEP 4: RUN GOOS=linux GARCH=amd64 CGO_ENABLED=0 go build -mod=vendor -o api-server .
[build-ui : build] {"level":"info","ts":1584507640.7401912,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-ui : build] STEP 1: FROM registry.access.redhat.com/rhscl/python-36-rhel7
[build-ui : build] Getting image source signatures
[build-ui : build] Copying blob sha256:6a4fa4bc2d06e942c0e92d69614b4ee30c2d409c95f29a3a22ece8087ce164be
[build-ui : build] Copying blob sha256:455ea8ab06218495bbbcb14b750a0d644897b24f8c5dcf9e8698e27882583412
[build-ui : build] Copying blob sha256:bb13d92caffa705f32b8a7f9f661e07ddede310c6ccfa78fb53a49539740e29b
[build-ui : build] Copying blob sha256:c8106f599d69375cbfc2ef44b11812ddc33938ab1e94860b02c262118f837611
[build-ui : build] Copying blob sha256:84e620d0abe585d05a7bed55144af0bc5efe083aed05eac1e88922034ddf1ed2
[build-ui : build] Copying config sha256:3c93c53ba3715f62aad12366410a1cd57957c39f573c0681807000d12f3cccdc
[build-ui : build] Writing manifest to image destination
[build-ui : build] Storing signatures
[build-ui : build] STEP 2: LABEL "io.openshift.s2i.build.image"="registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location"="."
[build-ui : build] error building at STEP "LABEL "io.openshift.s2i.build.image" "registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location" "."": error ensuring container path "/opt/app-root/src": lstat /var/lib/containers/storage/overlay/262cf5f36861100bf27c9eb5f9baa42f2471984ee129a5f1dd901d81cf3d4cbd/merged/opt: invalid argument
failed to get logs for task build-ui : container step-build has failed : [{"name":"","digest":"","key":"StartedAt","value":"2020-03-18T05:00:49Z","resourceRef":{}}]
[build-api : build] f72f609911547c6bf2364e63cf786987cd7189c74d787d585d659284b7feba77
[build-api : build] STEP 5: FROM scratch
[build-api : build] STEP 6: WORKDIR /app
a related issue
Hi,
I'm trying pipeline tutorial, just changed the repo and Dockerfile.
All resources created, when I run pipeline I'm hitting the following error:
Any hints what might be wrong? Here is pipeline and the Dockerfile
tkn pipelinerun logs build-and-deploy-run-hq4lz -f
[build-image : git-source-app-repo-qh8fd] {"level":"info","ts":1589824315.4050386,"caller":"git/git.go:105","msg":"Successfully cloned http://github.com/gasgithub/get-started-java.git @ master in path /workspace/source"}
[build-image : git-source-app-repo-qh8fd] {"level":"warn","ts":1589824315.4058552,"caller":"git/git.go:152","msg":"Unexpected error: creating symlink: symlink /tekton/home/.ssh /root/.ssh: file exists"}
[build-image : git-source-app-repo-qh8fd] {"level":"info","ts":1589824315.5597413,"caller":"git/git.go:133","msg":"Successfully initialized and updated submodules in path /workspace/source"}
[build-image : build] [STEP 1: FROM ibmcom/websphere-liberty:kernel-java8-ibmjava-ubi
[build-image : build] [Getting image source signatures
[build-image : build] [Copying blob sha256:58e1deb9693dfb1704ccce2f1cf0e4d663ac77098a7a0f699708a71549cbd924
...
[build-image : build] [0mCopying config sha256:25b630d683bb524a292779ef58d2200da5eda80ffe6f94652b91ac0ba16a202d
[[build-image : build] [Writing manifest to image destination
[[build-image : build] [Storing signatures
[[build-image : build] [STEP 2: COPY --chown=1001:0 target/GetStartedJava.war /config/apps/
[[build-image : build] [error dry-running "COPY --chown=1001:0 target/GetStartedJava.war /config/apps/": couldn't determine what "/var/lib/containers/storage/overlay/86fe61b71cde8535b700d3faaa10cb54715c976f1c3792ecc85623e0c614ba97/merged" is: stat /var/lib/containers/storage/overlay/86fe61b71cde8535b700d3faaa10cb54715c976f1c3792ecc85623e0c614ba97/merged: invalid argument
[mfailed to get logs for task build-image : container step-build has failed : [{"key":"StartedAt","value":"2020-05-18T17:51:55Z","resourceRef":{}}]
I ran into a couple of issues going through this tutorial.
workingDir
instead of workingdir
apply_manifest_task.yaml
has a typo:
workingdir: /workspace/source
should be
workingDir: /workspace/source
pipeline
ServiceAccountThe tutorial does not specify a ServiceAccount when creating the PipelineRun. So, it fails when pushing images to the internal registry:
tkn pipeline start build-and-deploy
Instead, we should run the PipelineRun under the pipeline
ServiceAccount
tkn pipeline start build-and-deploy --serviceaccount pipeline
This is not available at all for OKD 4.x and none of the CLI/manual installation works.
Since this tutorial expects the user to use OpenShift, it should guide users to use tkn
instead of oc
where applicable.
Hi all,
tested on Openshift CRC 4.2.13
getting this error
web console:
update-ui-image
step-patch
Error from server (NotFound): deployments.extensions "ui" not found
command line:
....
[build-ui : image-digest-exporter-grtqg] {"level":"warn","ts":1579104550.7637124,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build-ui : image-digest-exporter-grtqg] {"level":"info","ts":1579104550.7639525,"logger":"fallback-logger","caller":"imagedigestexporter/main.go:58","msg":"ImageResource api-image doesn't have an index.json file: stat /builder/home/image-outputs/image/index.json: no such file or directory"}
[apply-ui-manifests : git-source-api-repo-bgr9t] {"level":"warn","ts":1579104566.547371,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[apply-ui-manifests : git-source-api-repo-bgr9t] {"level":"info","ts":1579104569.0245762,"logger":"fallback-logger","caller":"git/git.go:103","msg":"Successfully cloned http://github.com/openshift-pipelines/vote-api.git @ master in path /workspace/source"}
[apply-ui-manifests : apply] Applying manifests in k8s directory
[apply-ui-manifests : apply] deployment.apps/api configured
[apply-ui-manifests : apply] service/api unchanged
[apply-ui-manifests : apply] -----------------------------------
[update-ui-image : patch] Error from server (NotFound): deployments.extensions "ui" not found
failed to get logs for task update-ui-image : container step-patch has failed
Following the steps in this tutorial and after implementing the workaround in #6, the Spring Petclinic sample app gets into a CrashLoopBackOff
with the following errors:
FailedScheduling:
Warning FailedScheduling 5m3s default-scheduler Binding rejected: Operation cannot be fulfilled on pods/binding "spring-petclinic-1-x2sct": pod spring-petclinic-1-x2sct is already assigned to node "ip-10-0-142-204.ec2.internal"
Liveness and Readiness Probe Issues:
Warning Unhealthy 5s (x4 over 35s) kubelet, ip-10-0-142-204.ec2.internal Readiness probe failed: Get http://10.130.2.56:8080/: dial tcp 10.130.2.56:8080: connect: connection refused
Warning Unhealthy 4s (x4 over 34s) kubelet, ip-10-0-142-204.ec2.internal Liveness probe failed: Get http://10.130.2.56:8080/: dial tcp 10.130.2.56:8080: connect: connection refused
Disabling the Liveness and Readiness probes in petclinic.yaml allows the application to successfully deploy through the example pipeline.
tkn pipeline start build-and-deploy
-w name=shared-workspace,claimName=source-pvc
-p deployment-name=vote-api
-p git-url=http://github.com/openshift-pipelines/vote-api.git
-p IMAGE=image-registry.openshift-image-registry.svc:5000/myproject/vote-api
TypeError
Description:
n is undefined
Component Trace:
in Unknown
in div
in div
in div
6431/t.a@https://console-openshift-console.apps-crc.testing/static/pipelinerun-details-chunk-ee0c16b8da458300f498.min.js:1:175890
Fo@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:55337
Ks@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:98261
Bs@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:84008
Ns@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:81035
Ds@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:79608
di/<@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:41759
t.unstable_runWithPriority@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:144:3878
li@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:41488
di@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:41705
pi@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:41640
Is@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:136:79935
notify@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:23:75933
a</t.notifyNestedSubs@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:23:75503
f</n.notifySubscribers@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:65:2428
a</t.handleChangeWrapper@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:23:75571
v@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:17:122529
b/</</<@https://console-openshift-console.apps-crc.testing/static/main-chunk-dbccb664872199d7c81d.min.js:1:89823
dispatch@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:17:126016
l/<@https://console-openshift-console.apps-crc.testing/static/main-chunk-dbccb664872199d7c81d.min.js:1:84211
a@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:120:167477
k/<@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:120:167599
l@https://console-openshift-console.apps-crc.testing/static/vendors~main-chunk-5d16dae3ac38abab85aa.min.js:120:170236
After issuing the command:
$ tkn pipeline start build-and-deploy
I'm seeing this in the log:
[build-ui : build] error building at STEP "LABEL "io.openshift.s2i.build.image" "registry.access.redhat.com/rhscl/python-36-rhel7" "io.openshift.s2i.build.source-location" "."": error ensuring container path "/opt/app-root/src": lstat /var/lib/containers/storage/overlay/5e00638bac323dbd1b4584674a5c9047b7ca6a32d63f84a75d4e72cd96e43827/merged/opt: invalid argument
failed to get logs for task build-ui : container step-build has failed : [{"name":"","digest":"","key":"StartedAt","value":"2020-03-05T07:51:38Z","resourceRef":{}}]
This is what I'm seeing in the task run YAML:
- container: step-build
imageID: >-
quay.io/buildah/stable@sha256:52a993631e5f13f142c1de0ac19ed2188a1a4190bf4530ecaecb23bece0289c3
name: build
terminated:
containerID: >-
cri-o://e3c259c8d8290069f646c0178b1c3c0c77d1b4dc04a951017abee83f21113d54
exitCode: 1
finishedAt: '2020-03-05T07:52:04Z'
reason: Error
startedAt: '2020-03-05T07:51:38Z'
Any idea what went wrong here? Thanks in advance!
I try it on openshift 4.2
NAME TYPE DETAILS
api-repo git url: http://github.com/openshift-pipelines/vote-api.git
ui-repo git url: http://github.com/openshift-pipelines/vote-ui.git
api-image image url: image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/api:latest
ui-image image url: image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/ui:latest
frances@francess-mbp pipelines-tutorial % tkn pipeline start build-and-deploy
? Choose the git resource to use for api-repo: api-repo (http://github.com/openshift-pipelines/vote-api.git)
? Choose the image resource to use for api-image: api-image (image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/api:latest)
? Choose the git resource to use for ui-repo: api-repo (http://github.com/openshift-pipelines/vote-api.git)
? Choose the image resource to use for ui-image: api-image (image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/api:latest)
Pipelinerun started: build-and-deploy-run-5w6c6
Showing logs...
task build-api failed: failed to run the pod build-and-deploy-run-5w6c6-build-api-wbjqd-pod-9c8501
task build-ui failed: failed to run the pod build-and-deploy-run-5w6c6-build-ui-fwkcd-pod-297c64
Morning,
my second Issue I did recognize after creating the trigger-template and the trigger-binding (which have been successful).
Always with trying apply the "trigger" yaml file I get the follow error message:
"error: unable to recognize "03_trigger.yaml": no matches for kind "Trigger" in version "triggers.tekton.dev/v1alpha1""
apiVersion: triggers.tekton.dev/v1alpha1
kind: Trigger
metadata:
name: vote-trigger
spec:
serviceAccountName: pipeline
bindings:
I did try out a couple of hints and clues in the GIT articles, without being successful yet.
TA
Wolfgang
@siamaksade
I'm testing this tutorial on ocp 4.2 using tkn cli v0.4.0 and I'm facing this error:
build-s2i : push] error copying layers and metadata from "containers-storage:[overlay@/var/lib/containers/storage+/var/run/containers/storage:overlay.imagestore=/var/lib/shared,overlay.mount_program=/usr/bin/fuse-overlayfs,overlay.mountopt=nodev,metacopy=on]image-registry.openshift-image-registry.svc:5000/pipelines-demo/spring-petclinic:latest" to "docker://image-registry.openshift-image-registry.svc:5000/pipelines-demo/spring-petclinic:latest": Error writing blob: Error initiating layer upload to /v2/pipelines-demo/spring-petclinic/blobs/uploads/ in image-registry.openshift-image-registry.svc:5000: unauthorized: authentication required
The cloned repositories do not have the 'release-tech-preview-3' branch referenced in this repository.
When triggering the pipeline, I am encountering the following issue:
[build : build-step-git-source-petclinic-git-4wq7q] {"level":"warn","ts":1564963582.9377377,"logger":"fallback-logger","caller":"logging/config.go:65","msg":"Fetch GitHub commit ID from kodata failed: "KO_DATA_PATH" does not exist or is empty"}
[build : build-step-git-source-petclinic-git-4wq7q] {"level":"info","ts":1564963583.5528753,"logger":"fallback-logger","caller":"git/git.go:102","msg":"Successfully cloned https://github.com/spring-projects/spring-petclinic @ master in path /workspace/source"}[build : build-step-generate] Application dockerfile generated in /gen-source/Dockerfile.gen
[build : build-step-image-digest-exporter-generate-l2bw2] []
[build : build-step-build] STEP 1: FROM registry.access.redhat.com/redhat-openjdk-18/openjdk18-openshift
[build : build-step-build] Getting image source signatures
[build : build-step-build] Copying blob sha256:5c2598df456066d90ae3ed81592c54247800071c7ee8845985a93db7e95e936f
[build : build-step-build] Copying blob sha256:dc4e07da33bca48edefbcba8dadefa8e7ffc6fe3e8ee4db140600a62862a16ac
[build : build-step-build] Copying blob sha256:50408d34b7db1a7cac449215c8bf82b020a4e61bd542f66a8766b4804f3882fe
[build : build-step-build] Copying config sha256:b1a978b29b74ee26fe1adf1c95a533cf56c815b87f9a742fac28ce493f9fc894
[build : build-step-build] Writing manifest to image destination
[build : build-step-build] Storing signatures
[build : build-step-build] STEP 2: LABEL "io.openshift.s2i.build.image"="registry.access.redhat.com/redhat-openjdk-18/openjdk18-openshift" "io.openshift.s2i.build.source-location"="."
[build : build-step-build] 8b2b389b626d89517df954c54d3715dce9d066c482e1580e85ce2c7938d25017
[build : build-step-build] STEP 3: USER root
[build : build-step-build] 4f804bba78e994166483a49012491687e9be8cd785085ac152105dcf86bd2278
[build : build-step-build] STEP 4: COPY upload/src /tmp/src
[build : build-step-build] error building at STEP "COPY upload/src /tmp/src": no files found matching "/workspace/upload/src": no such file or directoryfailed to get logs for task build : container build-step-build has failed : Error
After following the tutoriaI step-by-step, I get:
invalid input params: param types don't match the user-specified type: [TLSVERIFY]
OCP 4.2 on AWS. cluster-admin permissions.
Following the tutorial, this fails at the git clone step. I suspect the proxy settings aren't being applied during the build.
[build-ui : git-source-ui-repo-r28v5] {"level":"error","ts":1581440334.8529313,"logger":"fallback-logger","caller":"git/git.go:40","msg":"Error running git [fetch --depth=1 --recurse-submodules=yes origin master]: exit status 128\nfatal: unable to access 'http://github.com/openshift-pipelines/vote-ui.git/': Failed connect to github.com:80; Connection timed out\n","stacktrace":"github.com/tektoncd/pipeline/pkg/git.run\n\t/go/src/github.com/tektoncd/pipeline/pkg/git/git.go:40\ngithub.com/tektoncd/pipeline/pkg/git.Fetch\n\t/go/src/github.com/tektoncd/pipeline/pkg/git/git.go:91\nmain.main\n\t/go/src/github.com/tektoncd/pipeline/cmd/git-init/main.go:39\nruntime.main\n\t/usr/local/go/src/runtime/proc.go:198"}
# oc version
Client Version: v4.2.15
Server Version: 4.2.16
Kubernetes Version: v1.14.6+8bbaf43
Hi,
I am not able to complete the tutorial with an error related with the task deployment. I am not sure yet what dependency I'm missing, so thought of raising an issue for it:
joalmaraz$ oc create -f https://raw.githubusercontent.com/tektoncd/catalog/master/openshift-client/openshift-client-task.yaml
error: unable to recognize "https://raw.githubusercontent.com/tektoncd/catalog/master/openshift-client/openshift-client-task.yaml": no matches for kind "Task" in version "tekton.dev/v1alpha1"
Or locally referenced:
pipelines-tutorial joalmaraz$ oc create -f openshift-client-task.yaml
error: unable to recognize "openshift-client-task.yaml": no matches for kind "Task" in version "tekton.dev/v1alpha1"
joalmaraz$ oc version
oc v3.11.0+0cbc58b
kubernetes v1.11.0+d4cacc0
features: Basic-Auth
Server https://****:6443
kubernetes v1.14.0+42b6806
Version | State | Started | Completed
4.2.0-0.okd-2019-06-16-213454 | Completed | Jun 17, 10:11 am | Jun 17, 10:31 am
Operator is installed:
Thanks.
Jose
Trying this tutorial on Openshift 4.4 environment. In the Trigger pipeline section, when tried to run this command it throws error
tkn pipeline start build-and-deploy -w name=shared-workspace, volumeClaimTemplateFile=https://raw.githubusercontent.com/openshift/pipelines-tutorial/master/01_pipeline/03_persistent_volume_claim.yaml -p deployment-name=vote-api -p git-url=http://github.com/openshift-pipelines/vote-api.git -p IMAGE=image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/vote-api
Error: admission webhook "webhook.pipeline.tekton.dev" denied the request: mutation failed: cannot decode incoming new object: json: unknown field "volumeClaimTemplate"
Am I missing something here?
(Webhook content comes below this section in the tutorial)
A recent commit to master has added a workspaces
in the update-deployment task which isn't necessary and the tutorial fails to run successfully.
Version Info:
client version: dev 🙏😝
❯ git rev-parse --short HEAD
9a414070
Pipeline version: v0.16.3
Triggers version: v0.8.1
Steps:
./demo.sh setup
./demo.sh run
❯ tkn tr desc build-and-deploy-run-jrcf5-update-deployment-z2wl8
Name: build-and-deploy-run-jrcf5-update-deployment-z2wl8
Namespace: pipelines-tutorial
Task Ref: update-deployment
Service Account: pipeline
Timeout: 1h0m0s
Labels:
app.kubernetes.io/managed-by=tekton-pipelines
tekton.dev/pipeline=build-and-deploy
tekton.dev/pipelineRun=build-and-deploy-run-jrcf5
tekton.dev/pipelineTask=update-deployment
tekton.dev/task=update-deployment
🌡️ Status
STARTED DURATION STATUS
13 minutes ago --- Failed(TaskRunValidationFailed) <<<<< Fails Validation 🤯
I'm trying to retest this tutorial to make sure if this is still working on OCP 4.1 since I'm done all the steps successfully a few weeks ago. The PipelineRun is failed as below:
➜ spring-petclinic git:(master) tkn pipeline logs -f
? Select pipeline : petclinic-deploy-pipeline
? Select pipelinerun : petclinic-deploy-pipeline-run-xlmw9 started 4 seconds ago
[build : create-dir-image-g87x8] {"level":"warn","ts":1571376051.427172,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: open /var/run/ko/HEAD: no such file or directory"}
[build : create-dir-image-g87x8] {"level":"info","ts":1571376051.4284658,"logger":"fallback-logger","caller":"bash/main.go:64","msg":"Successfully executed command "sh -c mkdir -p /workspace/output/image"; output "}
[build : git-source-petclinic-git-svt2v] {"level":"warn","ts":1571376051.6579278,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from kodata failed: "ref: refs/heads/master" is not a valid GitHub commit ID"}
[build : git-source-petclinic-git-svt2v] {"level":"info","ts":1571376054.3768287,"logger":"fallback-logger","caller":"git/git.go:102","msg":"Successfully cloned https://github.com/spring-projects/spring-petclinic @ master in path /workspace/source"}
[build : gen-env-file] /bin/sh: MAVEN_CLEAR_REPO=${inputs.params.MAVEN_CLEAR_REPO}: bad substitution
Sometimes I have different errors:
[jboss@workspacem6t97jyjwma48bkf payment-service]$ tkn pipeline logs -f
? Select pipeline : petclinic-deploy-pipeline
? Select pipelinerun : petclinic-deploy-pipeline-run-72v9r started 17 seconds ago
[build : create-dir-image-sl8vk] {"level":"warn","ts":1571749550.4025996,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID from koda
ta failed: open /var/run/ko/HEAD: no such file or directory"}
[build : create-dir-image-sl8vk] {"level":"info","ts":1571749550.403944,"logger":"fallback-logger","caller":"bash/main.go:64","msg":"Successfully executed command "sh -c
mkdir -p /workspace/output/image"; output "}
[build : git-source-petclinic-git-tcg4m] {"level":"warn","ts":1571749551.1254249,"logger":"fallback-logger","caller":"logging/config.go:69","msg":"Fetch GitHub commit ID f
rom kodata failed: "ref: refs/heads/master" is not a valid GitHub commit ID"}
[build : git-source-petclinic-git-tcg4m] {"level":"info","ts":1571749553.8468623,"logger":"fallback-logger","caller":"git/git.go:102","msg":"Successfully cloned https://gi
thub.com/spring-projects/spring-petclinic @ master in path /workspace/source"}
[build : generate] Build failed
[build : generate] ERROR: An error occurred: stat ${inputs.params.PATH_CONTEXT}: no such file or directory
failed to get logs for task build : container step-generate has failed : Error
During investing this issue pr38, we noticed that this image is not exist. Can you help check?
Testing this tutorial on a OCP 4.1.2 version and after creating the PipelineRun, I'm checking the logs :
tkn pr logs petclinic-deploy-pipelinerun-6d94f -f
[build : build] [INFO] BUILD SUCCESS
[build : build] [INFO] ------------------------------------------------------------------------
[build : build] [INFO] Total time: 53.768 s
[build : build] [INFO] Finished at: 2019-06-21T08:58:28Z
[build : build] [INFO] Final Memory: 93M/197M
[build : build] [INFO] ------------------------------------------------------------------------
[build : build] [WARNING] The requested profile "openshift" could not be activated because it does not exist.
[build : build] INFO Copying deployments from target to /deployments...
[build : build] '/tmp/src/target/spring-petclinic-2.1.0.BUILD-SNAPSHOT.jar' -> '/deployments/spring-petclinic-2.1.0.BUILD-SNAPSHOT.jar'
[build : build] 8544c38aeb6febc5fcff824b9929639e723324458c1bd64d0afca308c8d42ce5
[build : build] STEP 8: CMD /usr/local/s2i/run
[build : build] STEP 9: COMMIT image-registry.openshift-image-registry.svc:5000/pipelines-tutorial/spring-petclinic
[build : build] 8aa00132f8b1ef9c19d1395cfd4836931d69797da7ac87b4a4a3d38970c59350
[build : image-digest-exporter-build-dlqm4] []
[build : push] Getting image source signatures
[build : push] unauthorized: authentication required
any ideas ?
I tried to update the Task s2i-java-8 from
- default: "true"
description: Verify the TLS on the registry endpoint (for push/pull to a non-TLS
registry)
name: TLSVERIFY
to
- default: "false"
description: Verify the TLS on the registry endpoint (for push/pull to a non-TLS
registry)
name: TLSVERIFY
but same error .
the OCP is a standard OCP 4.1.2 running on AWS (no advanced settings)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.