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

Take a compile time variable from the linker to set arm variant #996

Closed
wants to merge 2 commits into from
Closed

Take a compile time variable from the linker to set arm variant #996

wants to merge 2 commits into from

Conversation

PhoenixMage
Copy link
Contributor

@PhoenixMage PhoenixMage commented Jan 24, 2020

Fixes issue #992

Description

Takes a compile time variable from the linker to set the Arm variant for pulling from docker hub.

Submitter Checklist

These are the criteria that every PR should meet, please check them off as you
review them:

  • Includes unit tests
  • Adds integration tests if needed.

See the contribution guide for more details.

Reviewer Notes

  • The code flow looks good.
  • Unit tests and or integration tests added.

Release Notes

Describe any changes here so maintainer can include it in the release notes, or delete this block.

Examples of user facing changes:
- Skaffold config changes like
  e.g. "Add buildArgs to `Kustomize` deployer skaffold config."
- Bug fixes
  e.g. "Improve skaffold init behaviour when tags are used in manifests"
- Any changes in skaffold behavior
  e.g. "Artiface cachine is turned on by default."

@googlebot googlebot added the cla: yes CLA signed by all commit authors label Jan 24, 2020
@@ -144,8 +147,20 @@ func SHA256(r io.Reader) (string, error) {

// CurrentPlatform returns the v1.Platform on which the code runs
func currentPlatform() v1.Platform {
var archVariant string
if strings.HasPrefix(runtime.GOARCH, "arm") {
Copy link
Contributor

Choose a reason for hiding this comment

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

I am little confused how this works.
IIUC, we build a Kaniko binary on my local environment. It would contain the arm and archVariant thats on my machine right?

Does this mean, our Dockerfile should also change?

FROM golang:1.12
ARG GOARCH=amd64

@tejal29
Copy link
Contributor

tejal29 commented Jan 24, 2020

Thanks you for your contribution @PhoenixMage! Some gofmt issues and one question on if we need to change the way image is built.

@PhoenixMage
Copy link
Contributor Author

PhoenixMage commented Jan 24, 2020 via email

@cvgw cvgw self-assigned this Jan 25, 2020
@tejal29
Copy link
Contributor

tejal29 commented Jul 28, 2020

closed due to inactivity

@tejal29 tejal29 closed this Jul 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes CLA signed by all commit authors
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants