cmd: move the "upload" comand from bib here#396
Merged
mvo5 merged 13 commits intoosbuild:mainfrom Dec 9, 2025
Merged
Conversation
Add new command for uploading a disk image to AWS and registering it as an AMI. The command expects credentials from the environment and the keys match those that the AWS CLI uses.
Print error messages if either of the required env vars aren't set instead of having the upload function fail with a less helpful error message.
Create a new internal package called 'uploader' and move the core functionality for AWS uploads to a file called 'aws.go' in that package. The functions will be used by both the standalone uploader and bootc-image-builder to upload images as part of the build.
awscloud.NewDefault() already supports authentication via AWS_ACCESS_KEY_ID, credential file etc. No need for special cases or special command line options here.
There is a bug in the bib code right now that when uploading the AMI. It assume that the images are always build for the host architecture. But bib supports building/uploading cross-architecture images too. Thanks to Ondrej for spotting this.
Add a new `--progress` option that defaults to `text` and show upload progress when uploading an AMI.
This commit switches bib to the new uploader interface in images. This requires osbuild/images#1185
New linter problems arose after updating golangci-lint's version.
This commit fixes the issue that with an unset --target-arch the code will try to convert an empty string to an arch.Arch which then fails. This is a regression from osbuild/bootc-image-builder#1017 that was not caught. Closes: osbuild/bootc-image-builder#1029
Update go.mod and do the required AI changes for v0.197.0
Add an explaination why we do consider the "upload" command "legacy": ``` This contains the "legacy" upload command that was part of the original bootc-image-builder source. We need to keep it around and put it into the "bootc-image-builder" container to not break existing users. But it should not be used in the image-builder container or RPM. One big issue is that we do not have enough data about the image to know e.g. if it needs to be uploaded as a BIOS or hybrid image etc. ```
We do consider the upload command legacy and want to phase it out in favor of: a) just using the --upload flag from ibcli/bib b) a more rich version of this command that requires that we put more metadata into the images so that decisions like boot type are captured that are needed by many clouds So for now just print a warning so that people are aware.
achilleas-k
approved these changes
Dec 8, 2025
thozza
approved these changes
Dec 9, 2025
mvo5
added a commit
to mvo5/bootc-image-builder
that referenced
this pull request
Dec 9, 2025
This commit removes the upload command. It is still available in the ibcli git repo [0] but given that its not actually part of the bootc-image-builder container I wonder if we could simply remove it everywhere? [0] osbuild/image-builder-cli#396
achilleas-k
pushed a commit
to mvo5/bootc-image-builder
that referenced
this pull request
Dec 9, 2025
This commit removes the upload command. It is still available in the ibcli git repo [0] but given that its not actually part of the bootc-image-builder container I wonder if we could simply remove it everywhere? [0] osbuild/image-builder-cli#396
mvo5
added a commit
to mvo5/bootc-image-builder
that referenced
this pull request
Dec 9, 2025
This commit removes the upload command. It is still available in the ibcli git repo [0] but given that its not actually part of the bootc-image-builder container I wonder if we could simply remove it everywhere? [0] osbuild/image-builder-cli#396
mvo5
added a commit
to mvo5/bootc-image-builder
that referenced
this pull request
Dec 12, 2025
This commit removes the upload command. It is still available in the ibcli git repo [0] but given that its not actually part of the bootc-image-builder container I wonder if we could simply remove it everywhere? [0] osbuild/image-builder-cli#396
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Almost all code of "bootc-image-builder" is now part of "image-builder". This is the last remaining piece - we have an "upload" command in bib that needs moving over here. This branch moves it (with history) and also adds a deprecation warning and README.md (for our future selfs).