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

Implement Target support for ko builder #6447

Merged
merged 1 commit into from
Aug 20, 2021

Conversation

halvards
Copy link
Contributor

Description

This implements support for the Target config field for the ko builder.

The Target field allows users to specify a target for go build. This is necessary where the main package is not in the context directory.

Creates a testdata directory under ./pkg/skaffold/build/ko with test samples. This is to avoid depending on test samples from other packages.

Tracking: #6041
Related: #6054, #6437

This implements support for the Target config field for the ko builder.
The Target field allows users to specify a target for `go build`. This
is necessary where the main package is not in the context directory.

Tracking: GoogleContainerTools#6041
Related: GoogleContainerTools#6054, GoogleContainerTools#6437
@halvards halvards requested a review from a team as a code owner August 17, 2021 04:01
@google-cla google-cla bot added the cla: yes label Aug 17, 2021
@codecov
Copy link

codecov bot commented Aug 17, 2021

Codecov Report

Merging #6447 (825ea4b) into main (f88c88e) will increase coverage by 0.01%.
The diff coverage is 90.90%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #6447      +/-   ##
==========================================
+ Coverage   70.41%   70.42%   +0.01%     
==========================================
  Files         506      506              
  Lines       22847    22850       +3     
==========================================
+ Hits        16087    16093       +6     
+ Misses       5708     5705       -3     
  Partials     1052     1052              
Impacted Files Coverage Δ
pkg/skaffold/build/ko/build.go 63.15% <90.90%> (+3.15%) ⬆️
pkg/skaffold/log/stream/stream.go 85.71% <0.00%> (+14.28%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f88c88e...825ea4b. Read the comment docs.

@@ -36,6 +36,14 @@ type KoArtifact struct {
// Defaults to `all` to build for all platforms supported by the
// base image.
Platforms []string `yaml:"platforms,omitempty"`

Copy link
Member

Choose a reason for hiding this comment

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

👍 for temporary schema changes file.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

👍

@tejal29 tejal29 added the kokoro:force-run forces a kokoro re-run on a PR label Aug 17, 2021
@kokoro-team kokoro-team removed the kokoro:force-run forces a kokoro re-run on a PR label Aug 17, 2021
@tejal29 tejal29 enabled auto-merge (squash) August 17, 2021 04:30
@tejal29 tejal29 merged commit 7363674 into GoogleContainerTools:main Aug 20, 2021
@halvards halvards deleted the ko-target branch February 22, 2022 03:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants