Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to build a Go function with s2i directly on the cluster #2443

Closed
jrangelramos opened this issue Jul 24, 2024 · 1 comment · Fixed by #2471
Closed

Unable to build a Go function with s2i directly on the cluster #2443

jrangelramos opened this issue Jul 24, 2024 · 1 comment · Fixed by #2471

Comments

@jrangelramos
Copy link
Contributor

On cluster builds does not work for go function using s2i builder for either http and cloudevents default template.

Steps to reproduce

$ func create -l go /tmp/somefunc
$ func deploy -b s2i -p /tmp/somefunc --remote

Tekton task build and deploy logs

$ tkn pr logs
...
[build : build] STEP 1/8: FROM registry.access.redhat.com/ubi8/go-toolset:latest
[build : build] Trying to pull registry.access.redhat.com/ubi8/go-toolset:latest...
[build : build] Getting image source signatures
[build : build] Checking if image destination supports signatures
[build : build] Copying blob sha256:8694db102e5bd27fa30106f87d5a0f0c5ccccac0e5cc38ba56080d7559377096
[build : build] Copying blob sha256:7027f4e4058bde8aaa497e47562e962c293039ba16f5fbfd07ff43a0d1dbd5a2
[build : build] Copying blob sha256:b6a366ac05e5458bcf8b40dd8802b77ffbbe792e074a976b85ea818a92607e05
[build : build] Copying blob sha256:be575238ea985ef824635fbeaf7b33eaed98ef6ba1db1822ac0714f509304d17
[build : build] Copying config sha256:ac107e10470d56a8b99dbf9a405b63d0ca69af209e45c5fa426ec1b903d9dd93
[build : build] Writing manifest to image destination
[build : build] Storing signatures
[build : build] STEP 2/8: LABEL "io.openshift.s2i.build.image"="registry.access.redhat.com/ubi8/go-toolset:latest"       "io.openshift.s2i.build.source-location"="."
[build : build] --> 032d3d3a27a4
[build : build] STEP 3/8: USER root
[build : build] --> 4859baaa087a
[build : build] STEP 4/8: COPY upload/src /tmp/src
[build : build] --> 9005b977e66e
[build : build] STEP 5/8: RUN chown -R 1001:0 /tmp/src
[build : build] --> 7d829a5fe906
[build : build] STEP 6/8: USER 1001
[build : build] --> 56cb1bc8e4b6
[build : build] STEP 7/8: RUN /usr/libexec/s2i/assemble
[build : build] /tmp/src ~
[build : build] go: downloading github.com/cloudevents/sdk-go/v2 v2.5.0
[build : build] go: downloading github.com/json-iterator/go v1.1.10
[build : build] go: downloading github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421
[build : build] go: downloading github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742
[build : build] ~
[build : build] --> 523c6675a5be
[build : build] STEP 8/8: CMD /usr/libexec/s2i/run
[build : build] COMMIT image-registry.openshift-image-registry.svc:5000/knfunc-oncluster-test-3qh50k/goocb:latest
[build : build] --> e8052e243a7b
[build : build] Successfully tagged image-registry.openshift-image-registry.svc:5000/knfunc-oncluster-test-3qh50k/goocb:latest
[build : build] e8052e243a7b5afdf9efc3c8e8f8d05404a722792980a533e35e55d7923d149f
[build : build] Getting image source signatures
[build : build] Copying blob sha256:d2496918743b76651915b83422da63a7a7ba6f41c64970aeebad43e7421cf8fa
[build : build] Copying blob sha256:41fdab9a4e32b1a427aef2d9537ed8c34cae55ba76471c1a3b1e2a31819dacd6
[build : build] Copying blob sha256:5141d650520148139290774c3bf838490494cd29e02865689cb1615210cfaad1
[build : build] Copying blob sha256:09057cb70b4cc786df3b5a67120db8120d9ae445772ef020c90ad01af2b44032
[build : build] Copying blob sha256:fbfe83c51065a0d0b1e815715d4eec8e487f4978e54991e5d0ba8379d67ec654
[build : build] Copying blob sha256:4e29796b4201fba751b920fb5db529ac2be5dc80ea177b53d7c6e89a3cdc0e03
[build : build] Copying blob sha256:648d96915aaa6067011496eaf1d49f8ed260dd34d49c2a7079adba8f600ab2e7
[build : build] Copying config sha256:e8052e243a7b5afdf9efc3c8e8f8d05404a722792980a533e35e55d7923d149f
[build : build] Writing manifest to image destination
[build : build] sha256:ce4487700c579e0c837a80d41af08a9367bc4c19aae61c4e075b033d8b3d804d

[deploy : func-deploy] Waiting for Knative Service to become ready
[deploy : func-deploy] /usr/libexec/s2i/run: line 5: /opt/app-root/gobinary: Permission denied
[deploy : func-deploy] /usr/libexec/s2i/run: line 5: /opt/app-root/gobinary: Permission denied
[deploy : func-deploy] /usr/libexec/s2i/run: line 5: /opt/app-root/gobinary: Permission denied
[deploy : func-deploy] /usr/libexec/s2i/run: line 5: /opt/app-root/gobinary: Permission denied
@jrangelramos
Copy link
Contributor Author

/cc @lkingland @matejvasek

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant