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

Guidance: Adding a locally build .apk package #58

Open
aj185259 opened this issue Mar 28, 2024 · 1 comment
Open

Guidance: Adding a locally build .apk package #58

aj185259 opened this issue Mar 28, 2024 · 1 comment

Comments

@aj185259
Copy link

Hi all,

I'm using rules_apko to build our Alpine images, but any that require an apk package not provided by an online mirror doesn't seem to be possible. For instance if I wanted to build a melange built package or a package built by one of our other teams, it doesn't seem to be able to accommodate that.

The closest I've gotten is being able to apko lock a local package, but it can't make its way into the apko_image via the lockfile.

Any thoughts or guidance on this would be greatly appreciated.

Thanks!

@sfc-gh-mhazy
Copy link
Contributor

I think this is currently not supported but it sounds like a good feature request.

The changes needed would be non trivial though.
The place where the "remote package" is assumed is https://github.com/chainguard-dev/rules_apko/blob/1d78765293a0baf3f92ca49efa51d6c02b9c828e/apko/private/apk.bzl#L42C5-L42C21

There are analogous rules for apk_repository and apk_keyring

All of these are used in translate_apko_lock (

for package in lock_file["contents"]["packages"]:
). I think there or in apk_import would need to be some logic to distinguish local from remote packages.

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

No branches or pull requests

2 participants