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

Support bazel output_groups for tar targets #9524

Open
leungster opened this issue Sep 10, 2024 · 0 comments
Open

Support bazel output_groups for tar targets #9524

leungster opened this issue Sep 10, 2024 · 0 comments

Comments

@leungster
Copy link

leungster commented Sep 10, 2024

Expected behavior

I can specify an output_groups=tarball in my skaffold template to use the tarball from an oci_load bazel target.

Actual behavior

The oci_load run script is assumed to be the tarball and the output_groups is ignored for the tar ball path.
https://github.com/GoogleContainerTools/skaffold/blob/main/pkg/skaffold/build/bazel/build.go#L140

Information

  • Skaffold version: v2.9.0
  • Operating system: macOS 14.6.1
  • Installed via: github releases
  • Contents of skaffold.yaml:
# Builds the container image
build:
  artifacts:
    - image: service
      bazel:
        target: //path:image.tar
        args:
        - "output_groups=tarball"

Steps to reproduce the behavior

  1. Define a bazel target using oci_load
  2. Run skaffold with the skaffold yaml

Workaround

I worked around this by defining a filegroup and having skaffold point to that.

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