sparse-intern-71089
04/30/2021, 8:27 PMmany-psychiatrist-74327
04/30/2021, 8:28 PMexport const kubeconfig = pulumi.
all([ cluster.name, cluster.endpoint, cluster.masterAuth ]).
apply(([ name, endpoint, masterAuth ]) => {
const context = `${gcp.config.project}_${gcp.config.zone}_${name}`;
return `apiVersion: v1
clusters:
- cluster:
certificate-authority-data: ${masterAuth.clusterCaCertificate}
server: https://${endpoint}
name: ${context}
contexts:
- context:
cluster: ${context}
user: ${context}
name: ${context}
current-context: ${context}
kind: Config
preferences: {}
users:
- name: ${context}
user:
auth-provider:
config:
cmd-args: config config-helper --format=json
cmd-path: gcloud
expiry-key: '{.credential.token_expiry}'
token-key: '{.credential.access_token}'
name: gcp
`;
});
billowy-army-68599
pulumi stack output kubeconfig --show-secrets
many-psychiatrist-74327
04/30/2021, 8:35 PMmany-psychiatrist-74327
04/30/2021, 8:36 PMmany-psychiatrist-74327
04/30/2021, 8:36 PMmasterAuth
is treated as a secret by pulumi? 🤷♂️many-psychiatrist-74327
04/30/2021, 8:41 PM