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

Use File-Based Catalog Format #45

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

varad-ahirwadkar
Copy link
Contributor

This PR fixes: #27

@ppc64le-cloud-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: varad-ahirwadkar
Once this PR has been reviewed and has the lgtm label, please assign mkumatag for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

catalog/preamble_config_template.json Outdated Show resolved Hide resolved
@varad-ahirwadkar
Copy link
Contributor Author

varad-ahirwadkar commented Sep 24, 2024

It was failing to build the catalog image for ppc64le from non-power platform or without buildx. To fix this, using multistage container image.
Workflow testing is in progress

$(OPM) render $(BUNDLE_IMGS) >> $(TMP_DIR)/rsct-operator-catalog.json
$(OPM) generate dockerfile $(TMP_DIR) -i quay.io/operator-framework/opm:${OPM_VERSION}
## Apending Final stage for ppc64le
echo "FROM quay.io/operator-framework/opm:$(OPM_VERSION)-ppc64le" >> $(TMP_DIR).Dockerfile
Copy link
Member

Choose a reason for hiding this comment

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

you can include this line into the below Dockerfile_final_stage docker file itself and use ARG for replacing VERSION substitution

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I tried that approach, but it doesn't work because the ARG gets declared in the first stage and isn't accessible in the second stage.

Copy link
Member

Choose a reason for hiding this comment

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

can you adopt this --platform=linux/ppc64le instead of -ppc64le? long term solution - lets see if we can work with OPM team to generate the Dockerfile itself to support any target architecture(enhance generate command)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have tried using --platform=linux/ppc64le, it works locally but in workflow it pull x86 image.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

long term solution - lets see if we can work with OPM team to generate the Dockerfile itself to support any target architecture(enhance generate command)

sure

$(OPM) render $(BUNDLE_IMGS) >> $(TMP_DIR)/rsct-operator-catalog.json
$(OPM) generate dockerfile $(TMP_DIR) -i quay.io/operator-framework/opm:${OPM_VERSION}
## Apending Final stage for ppc64le
echo "FROM quay.io/operator-framework/opm:$(OPM_VERSION)-ppc64le" >> $(TMP_DIR).Dockerfile
Copy link
Member

Choose a reason for hiding this comment

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

can you adopt this --platform=linux/ppc64le instead of -ppc64le? long term solution - lets see if we can work with OPM team to generate the Dockerfile itself to support any target architecture(enhance generate command)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Migrate from Sqlite-Based to File-Based Catalog Format
3 participants