Skip to content

Commit

Permalink
chore: update go and rules_go version (#55)
Browse files Browse the repository at this point in the history
older versions of Go suffer from issues with DNS resolution when
cross-compiling. the root of the issue is that Go <1.20 uses a built-in
DNS resolver which doesn't know how to resolve addresses when connected
to any VPN, like AppGate. because of this, rules like `oci_push` cannot
push images to GovCloud registry, making it more difficult to do things
like deploy from a laptop in the event of an incident.

this DNS issue was fixed in 1.20 (see [this
article](https://danp.net/posts/macos-dns-change-in-go-1-20/)) for more
information.
  • Loading branch information
ethanfrogers authored Oct 19, 2023
1 parent 013ffef commit 707e411
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .bazelversion
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.2.0
5.4.0
8 changes: 4 additions & 4 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")

http_archive(
name = "io_bazel_rules_go",
sha256 = "f2dcd210c7095febe54b804bb1cd3a58fe8435a909db2ec04e31542631cf715c",
sha256 = "51dc53293afe317d2696d4d6433a4c33feedb7748a9e352072e2ec3c0dafd2c6",
urls = [
"https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.31.0/rules_go-v0.31.0.zip",
"https://github.com/bazelbuild/rules_go/releases/download/v0.31.0/rules_go-v0.31.0.zip",
"https://mirror.bazel.build/github.com/bazelbuild/rules_go/releases/download/v0.40.1/rules_go-v0.40.1.zip",
"https://github.com/bazelbuild/rules_go/releases/download/v0.40.1/rules_go-v0.40.1.zip",
],
)

Expand Down Expand Up @@ -90,7 +90,7 @@ load("@io_bazel_rules_go//go:deps.bzl", "go_register_toolchains", "go_rules_depe

go_rules_dependencies()

go_register_toolchains(version = "1.18")
go_register_toolchains(version = "1.20")

load("@rules_proto//proto:repositories.bzl", "rules_proto_dependencies", "rules_proto_toolchains")

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module github.com/DataDog/rules_oci

go 1.18
go 1.20

0 comments on commit 707e411

Please sign in to comment.