Skip to content

v0.1.0

Pre-release
Pre-release
Compare
Choose a tag to compare
@github-actions github-actions released this 16 Sep 15:02
· 47 commits to main since this release
eb7c404

Using Bzlmod with Bazel 6

  1. Enable with common --enable_bzlmod in .bazelrc.
  2. Add to your MODULE.bazel file:
bazel_dep(name = "rules_apko", version = "0.1.0")

Using WORKSPACE

Paste this snippet into your file:

load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
    name = "rules_apko",
    sha256 = "42d4e8a6732c01a374f15a6ca4a90695be84bb6829560d9998dcefd15b2ae667",
    strip_prefix = "rules_apko-0.1.0",
    url = "https://github.com/chainguard-dev/rules_apko/releases/download/v0.1.0/rules_apko-v0.1.0.tar.gz",
)

######################
# rules_apko setup #
######################
# Fetches the rules_apko dependencies.
# If you want to have a different version of some dependency,
# you should fetch it *before* calling this.
# Alternatively, you can skip calling this function, so long as you've
# already fetched all the dependencies.
load("@rules_apko//apko:repositories.bzl", "apko_register_toolchains", "rules_apko_dependencies")

rules_apko_dependencies()

apko_register_toolchains(name = "apko")

load("@rules_apko//apko:translate_lock.bzl", "translate_apko_lock")

translate_apko_lock(
    name = "example_lock",
    lock = "@//:apko.lock.json",
)

load("@example_lock//:repositories.bzl", "apko_repositories")

apko_repositories()

Initial setup

rules_apko requires a one-time setup to configure bazel to be able to make partial fetches.

Follow https://github.com/chainguard-dev/rules_apko/blob/main/docs/initial-setup.md for the setup.

What's Changed

New Contributors

Full Changelog: https://github.com/chainguard-dev/rules_apko/commits/v0.1.0