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

Make it easier to bring your own binary by supporting toolchain_utils pattern #5

Open
mikn opened this issue Nov 12, 2024 · 0 comments

Comments

@mikn
Copy link

mikn commented Nov 12, 2024

I notice that the toolchains for helm and kustomize are implemented using custom (and private) providers, and the executables are referred through these providers;

    kustomize_tool = ctx.toolchains[_kustomize_toolchain_type].kustomizeinfo.tool
    helm_tool = None
    args = ctx.actions.args()

    args.add(_runfile_path(ctx, kustomization.target_file))
    if kustomization.requires_helm:
        info = ctx.toolchains[_helm_toolchain_type].helminfo
        if not info:
            fail("No Helm toolchain is available; unable to proceed with invoking kustomize without it")
        helm_tool = info.tool

We were planning on using the excellent toolchain_utils that ARM is publishing to wrap our binary management system, but since the toolchain implementation is not using the executable field on platform_common.ToolchainInfo, we cannot do that.

Would you be open to using the executable field on the ToolchainInfo provider instead to pass the path to the rules from the toolchain to make it easier to BYOB (Bring Your Own Binary)?
Ref: https://gitlab.arm.com/bazel/toolchain_utils/-/blob/main/toolchain/info/rule.bzl?ref_type=heads

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

1 participant