treewide: replace rules_docker with rules_oci
rules_docker is not maintained anymore and recommends migration to
rules_oci
Change-Id: I089f3cf44888b3c3c0baa2c84a319b04b1a7dec4
Reviewed-on: https://review.monogon.dev/c/monogon/+/2712
Tested-by: Jenkins CI
Reviewed-by: Lorenz Brun <lorenz@monogon.tech>
diff --git a/cloud/shepherd/provider/equinix/BUILD.bazel b/cloud/shepherd/provider/equinix/BUILD.bazel
index 3363d7f..2ea4ee7 100644
--- a/cloud/shepherd/provider/equinix/BUILD.bazel
+++ b/cloud/shepherd/provider/equinix/BUILD.bazel
@@ -1,6 +1,4 @@
load("@io_bazel_rules_go//go:def.bzl", "go_binary", "go_library", "go_test")
-load("@io_bazel_rules_docker//container:container.bzl", "container_image")
-load("//build/static_binary_tarball:def.bzl", "static_binary_tarball")
go_library(
name = "equinix_lib",
@@ -59,15 +57,19 @@
visibility = ["//visibility:public"],
)
-static_binary_tarball(
+load("@rules_pkg//pkg:tar.bzl", "pkg_tar")
+
+pkg_tar(
name = "equinix_layer",
- executable = ":equinix",
+ srcs = [":equinix"],
)
-container_image(
- name = "equinix_container",
- base = "@go_image_base//image",
- entrypoint = ["/app/cloud/shepherd/provider/equinix/equinix_/equinix"],
+load("@rules_oci//oci:defs.bzl", "oci_image")
+
+oci_image(
+ name = "equinix_image",
+ base = "@distroless_base",
+ entrypoint = ["/equinix"],
tars = [
":equinix_layer",
"//cloud/takeover:takeover_layer",