Skip to content

Use build architecture as default platform#1394

Closed
Hritik14 wants to merge 1 commit into
anchore:mainfrom
Hritik14:main
Closed

Use build architecture as default platform#1394
Hritik14 wants to merge 1 commit into
anchore:mainfrom
Hritik14:main

Conversation

@Hritik14
Copy link
Copy Markdown

@Hritik14 Hritik14 commented Dec 7, 2022

One possible solution to #1391

Build is taking a lot of time, Not yet tested

Signed-off-by: Hritik V <hritik.vijay@cred.club>
@Hritik14
Copy link
Copy Markdown
Author

Can someone approve the workflows ?

@wagoodman
Copy link
Copy Markdown
Contributor

Hey, I've tried this out, however, if we go this direction we still need to change some behavior. Specifically, specifying a platform override will break input sources which do not allow for specifying platform:

        2023/01/12 15:15:12 error during command execution: 1 error occurred:
                * could not fetch image "test-fixtures/cache/stereoscope-fixture-image-secrets-6dbc1b7867bf6e50c7c4f681fb9d0ac9af3fd291aae2bb643f7d268789f85c77.tar": specified platform="linux/amd64" however image source="DockerTarball" does not support selecting platform

(the CLI tests show this)

Thanks for doing all of the upfront work with anchore/stereoscope#149 , #1391 , and this PR. I can make a few mods to this and see how it work as a PoC?

@wagoodman
Copy link
Copy Markdown
Contributor

On further thought, I don't think it makes sense to use the user override here to specify a default platform. I think it makes more sense to put in a fix in stereoscope conditionally based on if the user provided a platform or not (and if not, set the default based off of the host arch).

I'll open up a PR in stereoscope shortly.

@wagoodman wagoodman closed this Jan 12, 2023
@wagoodman
Copy link
Copy Markdown
Contributor

See anchore/stereoscope#152

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants