-
Notifications
You must be signed in to change notification settings - Fork 10
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
Ap/switch to rules oci #1
Conversation
because of native.package_relative_label
env: | ||
USE_BAZEL_VERSION: "5.3.1" | ||
USE_BAZEL_VERSION: "6.3.2" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we want to keep this consistent with .bazelversion
e2e/helloworld/BUILD.bazel
Outdated
# k8s_deploy( | ||
# name = "gitops_custom_path", | ||
# cluster = CLUSTER, | ||
# deployment_branch = "helloworld-gitops-custom-path", | ||
# gitops_path = "custom_cloud", | ||
# image_digest_tag = True, # test optional image tagging | ||
# image_registry = REGISTRY + "/k8s", # override the default registry for production | ||
# images = [":image"], | ||
# manifests = [ | ||
# "deployment.yaml", | ||
# "service.yaml", | ||
# ], | ||
# name_suffix = "-gitops-custom-path", | ||
# namespace = NAMESPACE, | ||
# user = USER, | ||
# ) | ||
|
||
# sh_test( | ||
# name = "k8s_deploy_test", | ||
# srcs = ["k8s_deploy_test.sh"], | ||
# args = [ | ||
# CLUSTER, | ||
# NAMESPACE, | ||
# ], | ||
# data = [ | ||
# ":canary.show", | ||
# ":mynamespace.show", | ||
# ":prod_west.show", | ||
# ], | ||
# deps = [ | ||
# "@bazel_tools//tools/bash/runfiles", | ||
# ], | ||
# ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
@@ -27,3 +34,13 @@ load("@com_adobe_rules_gitops//gitops:defs.bzl", "k8s_deploy") | |||
("mynamespace", "dev-cluster"), | |||
] | |||
] | |||
|
|||
# test expected transofmation results. | |||
write_source_files( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where is the test that asserts the equality of these files and the rendered output
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
write_source_fiels create the test and binary to update the golden file
examples/secrets/it_expected.txt
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this intended to be committed -- seems like it could be used ephemerally for test comparisons
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it is a golden file for the test
@@ -183,7 +183,7 @@ func main() { | |||
for _, target := range targets { | |||
log.Println("train", train, "target", target) | |||
bin := bazel.TargetToExecutable(target) | |||
exec.Mustex("", bin, "--nopush", "--nobazel", "--deployment_root", gitopsdir) | |||
exec.Mustex("", bin, "--nopush", "--deployment_root", gitopsdir) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remind me why we had --nobazel
originally?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
--nobazel is not used anywhere currently. It was an early attempt to make sure the binary is working under bazel run
as well as direct execution of a script in bazel-bin/ as create_gitops_prs run it. Later it was achieved without using of any command line flags but this historical artifact remains.
gitops/provider.bzl
Outdated
# "legacy_image_name", # DEPRECATED AND REMOVED short name | ||
# "registry", DEPRECATED AND REMOVED. use repository |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove?
Co-authored-by: michaelschiff <[email protected]>
…tops into ap/switch_to_rules_oci
Any blockers on this PR? |
Deprecate and remove rules_docker
switch to rules_oci
fixes #3