OpenLiberty / open-liberty-s2i

Eclipse Public License 1.0
14 stars 14 forks source link

error building at STEP "RUN /usr/libexec/s2i/assemble": exit status 127 #57

Open nmm131 opened 2 years ago

nmm131 commented 2 years ago

The openliberty/open-liberty-s2i:latest builder image was used in an S2I Tekton Task and the following error was outputted:

+ [[ false == \t\r\u\e ]]
+ buildah bud --storage-driver=vfs --tls-verify=false --layers -f /gen-source/Dockerfile.gen -t image-registry.openshift-image-registry.svc:5000/default/s2i-pipeline-run .
STEP 1: FROM open-liberty
Getting image source signatures
Copying blob sha256:f3e90b0b2b823eb843b3e1d2187948b54d8ff70c79db6782e5c0b87b4ef4ae6d
...truncated...
Copying config sha256:16c7b40ecf15cbb9209de51f7bd17db80477af1ea59ada67a921b5f68ea9bb66
Writing manifest to image destination
Storing signatures
STEP 2: LABEL "io.openshift.s2i.build.image"="open-liberty"       "io.openshift.s2i.build.source-location"="."
--> 0e2c97eeefd
STEP 3: USER root
--> 9fe63b87925
STEP 4: COPY upload/src /tmp/src
--> 20d9e5d32f2
STEP 5: RUN chown -R 1001:0 /tmp/src
--> 4bbb39417e0
STEP 6: USER 1001
--> 4be4c8e46e6
STEP 7: RUN /usr/libexec/s2i/assemble
/bin/sh: 1: /usr/libexec/s2i/assemble: not found
subprocess exited with status 127
subprocess exited with status 127
error building at STEP "RUN /usr/libexec/s2i/assemble": exit status 127

The STEP 7: RUN /usr/libexec/s2i/assemble Dockerfile step cannot run successfully and receives an exit status of 127. It appears as though the openliberty/open-liberty-s2i:latest builder image is missing the /usr/libexec/s2i/assemble file required by this step. Has this builder image been tested to be compatible with the S2I Tekton Task?

brenthdaniel commented 2 years ago

Hi, S2I relies on the io.openshift.s2i.scripts-url parameter to determine where the scripts are located. In the liberty S2I images, this is set to /usr/local/s2i:

docker inspect --format='{{ index .Config.Labels "io.openshift.s2i.scripts-url" }}' openliberty/open-liberty-s2i
image:///usr/local/s2i

Is this property being set to /usr/libexec/s2i somewhere in your pipeline?

I did try out the s2i tekton task at one point, but it's been quite a while.

nmm131 commented 2 years ago

Hi, there is the following S2I Tekton Task parameter:

PATH_CONTEXT: Source path from where s2i command need to be run (default: .).

Previously, I did not specify this parameter. This must mean I am using the default value of .

I provided that parameter using the following YAML in my S2I Tekton Task:

- name: PATH_CONTEXT
  value: /usr/local

However, the above YAML did not work. I also tried the following YAML paths without success:

/usr/local/s2i
/usr/libexec
/usr/libexec/s2i
/usr

This parameter does not appear to be changing the following path: /usr/libexec/s2i/assemble