sparse-intern-71089
10/22/2018, 5:52 PMcreamy-potato-29402
10/22/2018, 6:37 PMorange-tailor-85423
10/22/2018, 6:37 PMorange-tailor-85423
10/22/2018, 6:38 PMcreamy-potato-29402
10/22/2018, 6:38 PMserviceAccountId
with newserviceaccount.metadata.get()
, which does not seem right. You uprobably want newserviceaccount.metadata.apply(m => m.name)
creamy-potato-29402
10/22/2018, 6:38 PMorange-tailor-85423
10/22/2018, 6:38 PMcreamy-potato-29402
10/22/2018, 6:39 PMcreamy-potato-29402
10/22/2018, 6:39 PMcreamy-potato-29402
10/22/2018, 6:39 PMgoogle_service_account.k8s_node.name
?creamy-potato-29402
10/22/2018, 6:39 PM.metadata.name
?creamy-potato-29402
10/22/2018, 6:40 PMgoogle_service_account
, not a Kubernetes ServiceAccount
orange-tailor-85423
10/22/2018, 6:40 PMcreamy-potato-29402
10/22/2018, 6:41 PMorange-tailor-85423
10/22/2018, 6:41 PMcreamy-potato-29402
10/22/2018, 6:41 PMorange-tailor-85423
10/22/2018, 6:42 PMorange-tailor-85423
10/22/2018, 6:42 PMcreamy-potato-29402
10/22/2018, 6:43 PMcreamy-potato-29402
10/22/2018, 6:49 PMnew k8s.core.v1.ServiceAccount
, but you need new new gcp.serviceAccount.Account(...)
right?orange-tailor-85423
10/22/2018, 7:39 PMorange-tailor-85423
10/22/2018, 7:39 PMorange-tailor-85423
10/22/2018, 7:40 PMorange-tailor-85423
10/22/2018, 7:40 PMcreamy-potato-29402
10/22/2018, 7:41 PMcreamy-potato-29402
10/22/2018, 7:41 PMcreamy-potato-29402
10/22/2018, 7:41 PMorange-tailor-85423
10/22/2018, 7:41 PMorange-tailor-85423
10/22/2018, 7:42 PMorange-tailor-85423
10/22/2018, 7:42 PM${clusterName}-k8s-node1
,
displayName: Service Account - ${clusterName} - K8s node
}
)
return sa
}orange-tailor-85423
10/22/2018, 7:42 PMorange-tailor-85423
10/22/2018, 7:42 PMcreamy-potato-29402
10/22/2018, 7:43 PMfunction foo() {
return [new gcp.serviceAccount.Account(...), new gcp.serviceAccount.IAMMember(...)]
}
orange-tailor-85423
10/22/2018, 7:43 PMorange-tailor-85423
10/22/2018, 7:44 PMcreamy-potato-29402
10/22/2018, 7:44 PMorange-tailor-85423
10/22/2018, 7:45 PMorange-tailor-85423
10/22/2018, 7:45 PMorange-tailor-85423
10/22/2018, 7:45 PMcreamy-potato-29402
10/22/2018, 7:46 PMexport class IamServiceAccouunt extends pulumi.ComponentResource {
private readonly sa: gcp.serviceAccount.Account;
private readonly iam: gcp.serviceAccount.IAMMember;
constructor(...) {
<http://this.sa|this.sa> = new gcp.serviceAccount.Account(...)
this.iam = new gcp.serviceAccount.IAMMember(...)
}
}
creamy-potato-29402
10/22/2018, 7:47 PMnew IamServiceAccount(...)