-
Notifications
You must be signed in to change notification settings - Fork 41
/
action.yml
114 lines (94 loc) · 3.52 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
# Copyright 2020 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: 'Get GKE Credentials'
author: 'Google LLC'
description: |-
Authenticate to a Google Kubernetes Engine (GKE) cluster by generating an
emphemeral kubeconfig to use with kubectl, helm, etc.
inputs:
cluster_name:
description: |-
Name of the cluster for which to get credentials. This can be specified as
a full resource name:
projects/<project>/locations/<location>/clusters/<cluster>
In which case the `project_id` and `location` inputs are optional. If only
specified as a name:
<cluster>
then both the `project_id` and `location` may be required.
required: true
location:
description: |-
Location (region or zone) in which the cluster resides. This value is
required unless `cluster_name` is a full resource name.
required: false
project_id:
description: |-
Project ID where the cluster is deployed. If provided, this will override
the project configured by previous steps or environment variables. If not
provided, the project will be inferred from the environment, best-effort.
required: false
context_name:
description: |-
Name to use when creating the `kubectl` context. If not specified, the
default value is `gke_<project>_<location>_<cluster>`.
required: false
namespace:
description: |-
Name of the Kubernetes namespace to use within the context.
required: false
use_auth_provider:
description: |-
Set this to true to use the Google Cloud auth plugin in `kubectl` instead
of inserting a short-lived access token.
default: 'false'
required: false
use_internal_ip:
description: |-
Set this to true to use the internal IP address for the cluster endpoint.
This is mostly used with private GKE clusters.
default: 'false'
required: false
use_connect_gateway:
description: |-
Set this to true to use the [Connect Gateway
endpoint](https://cloud.google.com/anthos/multicluster-management/gateway)
to connect to cluster.
default: 'false'
required: false
fleet_membership_name:
description: |-
Fleet membership name to use for generating Connect Gateway endpoint, of
the form:
projects/<project>/locations/<location>/memberships/<membership>
This only applies if `use_connect_gateway` is true. Defaults to auto
discovery if empty.
required: false
quota_project_id:
description: |-
Project ID from which to pull quota. The caller must have
`serviceusage.services.use` permission on the project. If unspecified,
this defaults to the project of the authenticated principle. This is an
advanced setting, most users should leave this blank.
required: false
outputs:
kubeconfig_path:
description: |-
Path on the local filesystem where the generated Kubernetes configuration
file resides.
branding:
icon: 'lock'
color: 'blue'
runs:
using: 'node20'
main: 'dist/index.js'