Skip to content

Commit

Permalink
Make upload to LFS a single task
Browse files Browse the repository at this point in the history
Signed-off-by: Enrique Belarte Luque <[email protected]>
  • Loading branch information
enriquebelarte committed Feb 11, 2025
1 parent 0ef5bd9 commit c1c3a75
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions .tekton/upload-signed.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,15 @@ spec:
image: registry.redhat.io/ubi9/skopeo@sha256:713f01d02801350e32a6bce4285bbf93a8032444c4cac5d6e00e639b342dc0f0
script: |
skopeo copy docker://$(params.containerimage) dir:/tmp/drivers-image
ls -l /tmp/drivers-image/
# mkdir -p /tmp/driver-rootfs
# for layer in /tmp/drivers-image/blobs/sha256/*; do
# tar -tf "$layer" | grep '^opt/drivers'
# if [ $? -eq 0 ]; then
# tar -xvf "$layer" -C /tmp/driver-rootfs
# fi
# done
# cp -r /tmp/driver-rootfs/opt/drivers/ $(workspaces.drivers-dir.path)/
#
mkdir -p /tmp/driver-rootfs
for layer in $(ls -1t | grep -v 'manifest.json\|version'); do
tar -xvf "$layer" -C /tmp/image-rootfs
if [ $? -eq 0 ]; then
tar -xvf "$layer" -C /tmp/driver-rootfs
fi
done
cp -r /tmp/driver-rootfs/opt/drivers/ $(workspaces.drivers-dir.path)/
- name: git-upload-lfs
image: registry.access.redhat.com/ubi9/toolbox@sha256:7ea2a799a9cf6b0111f16418039ce0b7b30f5f764747960ce3a1dea4d89b78d8
workingDir: /var/workdir/source
Expand Down

0 comments on commit c1c3a75

Please sign in to comment.