-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Change the path used by the image digest exporter to the standard out… #1467
Conversation
The following is the coverage report on pkg/.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we need a docs update probs, and I'm a bit confused, are these docs wrong https://github.com/tektoncd/pipeline/blob/master/docs/resources.md#surfacing-the-image-digest-built-in-a-task which way we default to /workspace/output/{resource-name}
or are we talking about 2 different paths?
Name: "create-dir-default-image-output-mz4c7", | ||
Image: "override-with-bash-noop:latest", | ||
Command: []string{"/ko-app/bash"}, | ||
Args: []string{"-args", "mkdir -p /builder/home/image-outputs/outputimage"}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
question: do we not still want this test but with the new path? or do you we feel like this is already covered somewhere else/
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The function that this was testing got deleted, it now uses the normal output directory creation stuff, which is tested: https://github.com/tektoncd/pipeline/blob/master/pkg/reconciler/taskrun/resources/output_resource_test.go#L171
Wow, those docs are currently wrong then, and I guess my change makes them right? |
7b7a0af
to
e801460
Compare
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
/test pull-tekton-pipeline-integration-tests |
@@ -124,7 +119,6 @@ type Inputs struct { | |||
type TaskResource struct { | |||
ResourceDeclaration `json:",inline"` | |||
// +optional | |||
OutputImageDir string `json:"outputImageDir,omitempty"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is an API change, right? Would it be worth supporting this field in a deprecated state for a version?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So it's technically on the API, but as you can see up in image_resource.go it is never actually set during the initialization of the resource. I don't think it's actually functional right now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's technically part of the API, but I think it's unused. You can see that this value is never copied from the resource params into the resource in the constructor in image_resource.go.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is causing a issue, because we do have resources with outputImageDir
and they cannot be updated now :(
…put path structure. Previously we were writing output digests to /builder/home/image-output-paths. This commit unifies that system and expects tasks to output these files to /workspace/output/<resource name>. This does introduce a change in behavior, but support is retained for the old location. A warning is logged if the binary finds an index.json in the old location.
The following is the coverage report on pkg/.
|
The following is the coverage report on pkg/.
|
/lgtm |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: bobcatfish The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
This support was left in for one release after deprecation in tektoncd#1467, which was released in 0.9.0. It can now be safely removed.
This support was left in for one release after deprecation in #1467, which was released in 0.9.0. It can now be safely removed.
…put path structure.
Previously we were writing output digests to /builder/home/image-output-paths. This commit
unifies that system and expects tasks to output these files to /workspace/output/.
This does introduce a change in behavior, but support is retained for the old location. A warning
is logged if the binary finds an index.json in the old location.
Changes
Submitter Checklist
These are the criteria that every PR should meet, please check them off as you
review them:
See the contribution guide for more details.
Double check this list of stuff that's easy to miss:
cmd
dir, please updatethe release Task to build and release this image.
Reviewer Notes
If API changes are included, additive changes must be approved by at least two OWNERS and backwards incompatible changes must be approved by more than 50% of the OWNERS, and they must first be added in a backwards compatible way.
Release Notes