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

Add vendored-source logic to full release pipeline #1340

Merged
merged 1 commit into from
Oct 10, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions cmd/entrypoint/kodata/LICENSE
1 change: 1 addition & 0 deletions cmd/entrypoint/kodata/VENDOR-LICENSE
13 changes: 13 additions & 0 deletions tekton/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,19 @@ spec:
# Change to directory with our .ko.yaml
cd /workspace/go/src/github.com/tektoncd/pipeline

# For each cmd/* directory, include a full gzipped tar of all source in
# vendor/. This is overkill. Some deps' licenses require the source to be
# included in the container image when they're used as a dependency.
# Rather than trying to determine which deps have this requirement (and
# probably get it wrong), we'll just targz up the whole vendor tree and
# include it. As of 9/20/2019, this amounts to about 11MB of additional
# data in each image.
TMPDIR=$(mktemp -d)
tar cvfz ${TMPDIR}/source.tar.gz vendor/
for d in cmd/*; do
ln -s ${TMPDIR}/source.tar.gz ${d}/kodata/
done
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i wish we had a Task (or even maybe a reusable step??? #1260 ) we could test and reuse for this bit of bash :D

p.s. just a thought - i think i would have made this a separate step? probably just a stylistic difference tho


# Publish images and create release.yaml
ko resolve --preserve-import-paths -f /workspace/go/src/github.com/tektoncd/pipeline/config/ > /workspace/output/bucket/latest/release.yaml
volumeMounts:
Expand Down