mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-12-10 05:31:11 -05:00
bazel: add terrafrom to //:check and //:generate
Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
This commit is contained in:
parent
2693936906
commit
8d3fe6f477
7 changed files with 221 additions and 71 deletions
8
bazel/toolchains/BUILD.terraform.bazel
Normal file
8
bazel/toolchains/BUILD.terraform.bazel
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
genrule(
|
||||
name = "terraform_bin",
|
||||
srcs = ["terraform"],
|
||||
outs = ["terraform_bin_out"],
|
||||
cmd = "cp $< $@", # Copy the binary to the output directory.
|
||||
executable = True,
|
||||
visibility = ["//visibility:public"],
|
||||
)
|
||||
|
|
@ -3,7 +3,9 @@
|
|||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
||||
|
||||
def ci_deps():
|
||||
"""Install CI dependencies"""
|
||||
_shellcheck_deps()
|
||||
_terraform_deps()
|
||||
|
||||
def _shellcheck_deps():
|
||||
http_archive(
|
||||
|
|
@ -31,3 +33,37 @@ def _shellcheck_deps():
|
|||
strip_prefix = "shellcheck-v0.9.0",
|
||||
build_file = "//bazel/toolchains:BUILD.shellcheck.bazel",
|
||||
)
|
||||
|
||||
def _terraform_deps():
|
||||
http_archive(
|
||||
name = "com_github_hashicorp_terraform_linux_amd64",
|
||||
build_file = "//bazel/toolchains:BUILD.terraform.bazel",
|
||||
urls = [
|
||||
"https://releases.hashicorp.com/terraform/1.4.2/terraform_1.4.2_linux_amd64.zip",
|
||||
],
|
||||
sha256 = "9f3ca33d04f5335472829d1df7785115b60176d610ae6f1583343b0a2221a931",
|
||||
)
|
||||
http_archive(
|
||||
name = "com_github_hashicorp_terraform_linux_arm64",
|
||||
build_file = "//bazel/toolchains:BUILD.terraform.bazel",
|
||||
urls = [
|
||||
"https://releases.hashicorp.com/terraform/1.4.2/terraform_1.4.2_linux_arm64.zip",
|
||||
],
|
||||
sha256 = "39c182670c4e63e918e0a16080b1cc47bb16e158d7da96333d682d6a9cb8eb91",
|
||||
)
|
||||
http_archive(
|
||||
name = "com_github_hashicorp_terraform_darwin_amd64",
|
||||
build_file = "//bazel/toolchains:BUILD.terraform.bazel",
|
||||
urls = [
|
||||
"https://releases.hashicorp.com/terraform/1.4.2/terraform_1.4.2_darwin_amd64.zip",
|
||||
],
|
||||
sha256 = "c218a6c0ef6692b25af16995c8c7bdf6739e9638fef9235c6aced3cd84afaf66",
|
||||
)
|
||||
http_archive(
|
||||
name = "com_github_hashicorp_terraform_darwin_arm64",
|
||||
build_file = "//bazel/toolchains:BUILD.terraform.bazel",
|
||||
urls = [
|
||||
"https://releases.hashicorp.com/terraform/1.4.2/terraform_1.4.2_darwin_arm64.zip",
|
||||
],
|
||||
sha256 = "af8ff7576c8fc41496fdf97e9199b00d8d81729a6a0e821eaf4dfd08aa763540",
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue