hscloud/bgpwtf/cccampix/BUILD
Sergiusz Bazanski 5f9b1ecd67 rules_pip: update to new version
rules_pip has a new version [1] of their rule system, incompatible with the
version we used, that fixes a bunch of issues, notably:
 - explicit tagging of repositories for PY2/PY3/PY23 support
 - removal of dependency on host pip (in exchange for having to vendor
   wheels)
 - higher quality tooling for locking

We update to the newer version of pip_rules, rename the external
repository to pydeps and move requirements.txt, the lockfile and the
newly vendored wheels to third_party/, where they belong.

[1] - https://github.com/apt-itude/rules_pip/issues/16

Change-Id: I1065ee2fc410e52fca2be89fcbdd4cc5a4755d55
2019-09-25 14:05:07 +02:00

48 lines
1.2 KiB
Python

load("@io_bazel_rules_docker//container:container.bzl", "container_image", "container_layer", "container_push")
load("@subpar//:subpar.bzl", "par_binary")
par_binary(
name = "ripe-sync",
srcs = [
"ripe-sync.py",
],
deps = [
"@pydeps//grpcio",
"@pydeps//requests",
"//bgpwtf/cccampix/proto:ix_py_proto",
],
legacy_create_init = False,
zip_safe = False,
)
container_layer(
name = "layer_bin",
files = [
"//bgpwtf/cccampix:ripe-sync.par",
"//bgpwtf/cccampix/irr:irr",
"//bgpwtf/cccampix/pgpencryptor:pgpencryptor",
"//bgpwtf/cccampix/peeringdb:peeringdb",
"//bgpwtf/cccampix/verifier:verifier",
"//bgpwtf/cccampix/frontend:frontend.par",
],
directory = "/ix/",
)
container_image(
name = "runtime",
base = "@prodimage-bionic//image",
layers = [
":layer_bin",
"//bgpwtf/cccampix/octorpki:layer_bin",
"//bgpwtf/cccampix/octorpki:layer_tals",
],
)
container_push(
name = "push",
image = ":runtime",
format = "Docker",
registry = "registry.k0.hswaw.net",
repository = "bgpwtf/cccampix",
tag = "{BUILD_TIMESTAMP}-{STABLE_GIT_COMMIT}",
)