Skip to content

Commit d1f4015

Browse files
committed
Duplicate the deprecated GCP auth instead
Signed-off-by: methylDragon <methylDragon@google.com>
1 parent 1a26c6b commit d1f4015

File tree

4 files changed

+417
-3
lines changed

4 files changed

+417
-3
lines changed

docs/how-to/deploy-from-sources.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,11 @@ and 18.04) Linux.
1414
select or create a project.
1515
1. Make sure that [billing][modify-project] is enabled for your project.
1616
1. [Install the Cloud SDK][cloud-sdk]. When prompted, choose the project that you created above.
17-
1. After installing the Cloud SDK, install the `kubectl` command-line tool:
17+
1. After installing the Cloud SDK, install the `kubectl` command-line tool and the GKE auth plugin:
1818

1919
```shell
2020
gcloud components install kubectl
21+
gcloud components gke-gcloud-auth-plugin
2122
```
2223

2324
If you're using Debian or Ubuntu, you may need to use `apt install kubectl` instead.

src/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ require (
6464
github.com/google/go-cmp v0.6.0
6565
github.com/googlecloudrobotics/ilog v0.0.0-20231123101900-2533d3d7f8e1
6666
github.com/sirupsen/logrus v1.9.0
67+
k8s.io/klog/v2 v2.110.1
6768
)
6869

6970
require (
@@ -139,7 +140,6 @@ require (
139140
gopkg.in/yaml.v2 v2.4.0 // indirect
140141
gopkg.in/yaml.v3 v3.0.1 // indirect
141142
k8s.io/component-base v0.28.4 // indirect
142-
k8s.io/klog/v2 v2.110.1 // indirect
143143
k8s.io/kube-openapi v0.0.0-20231129212854-f0671cc7e66a // indirect
144144
k8s.io/utils v0.0.0-20231127182322-b307cd553661 // indirect
145145
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect

src/go/tests/BUILD.bazel

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
load("@io_bazel_rules_go//go:def.bzl", "go_test")
1+
load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
22

33
go_test(
44
name = "go_default_test",
55
size = "large",
66
timeout = "long",
77
srcs = ["k8s_integration_test.go"],
8+
embed = [":go_default_library"],
89
tags = ["external"],
910
deps = [
1011
"//src/go/pkg/apis/apps/v1alpha1:go_default_library",
@@ -31,3 +32,19 @@ sh_test(
3132
"manual",
3233
],
3334
)
35+
36+
go_library(
37+
name = "go_default_library",
38+
srcs = ["k8s_integration_test_auth_helper.go"],
39+
importpath = "github.com/googlecloudrobotics/core/src/go/tests",
40+
visibility = ["//visibility:public"],
41+
deps = [
42+
"@io_k8s_apimachinery//pkg/util/net:go_default_library",
43+
"@io_k8s_apimachinery//pkg/util/yaml:go_default_library",
44+
"@io_k8s_client_go//rest:go_default_library",
45+
"@io_k8s_client_go//util/jsonpath:go_default_library",
46+
"@io_k8s_klog_v2//:go_default_library",
47+
"@org_golang_x_oauth2//:go_default_library",
48+
"@org_golang_x_oauth2//google:go_default_library",
49+
],
50+
)

0 commit comments

Comments
 (0)