-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
/
kubeconfig.tpl
38 lines (34 loc) · 824 Bytes
/
kubeconfig.tpl
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
apiVersion: v1
preferences: {}
kind: Config
clusters:
- cluster:
server: ${endpoint}
certificate-authority-data: ${cluster_auth_base64}
name: ${kubeconfig_name}
contexts:
- context:
cluster: ${kubeconfig_name}
user: ${kubeconfig_name}
name: ${kubeconfig_name}
current-context: ${kubeconfig_name}
users:
- name: ${kubeconfig_name}
user:
exec:
apiVersion: client.authentication.k8s.io/v1alpha1
command: ${aws_authenticator_command}
args:
%{~ for i in aws_authenticator_command_args }
- "${i}"
%{~ endfor ~}
%{ for i in aws_authenticator_additional_args }
- ${i}
%{~ endfor ~}
%{ if length(aws_authenticator_env_variables) > 0 }
env:
%{~ for k, v in aws_authenticator_env_variables ~}
- name: ${k}
value: ${v}
%{~ endfor ~}
%{ endif }