broad-helmet-79436
01/22/2020, 9:49 AMmany-lock-25065
01/27/2020, 3:18 PMpulumi up
. Instead, we need one pulumi up
where the import
simply reflects the existing resource, and then another one where we edit the code to change the resource. We've verified this multi-stage flow works, but it feels clunky (currently we have to manually edit the code between the first and second pulumi up). Are there any tricks we can use to combine into a single stage?
One thought was that maybe there is a variable that denotes whether or not the resource is already referenced. Then we could run pulumi twice, and use a switch statement to distinguish the two cases. Feels very hacky though.able-crayon-21563
01/27/2020, 9:52 PMconst certManagerResources = new k8s.yaml.ConfigFile("cm", {
file: `<https://github.com/jetstack/cert-manager/releases/download/v0.13.0/cert-manager.yaml>`
})
Am finding that the preview hangs. v1.9.0. Thoughts?limited-rainbow-51650
01/28/2020, 9:49 AMconst privatePullCredentials = new kubernetes.core.v1.Secret('dockerprivatepull', {
type: "<http://kubernetes.io/dockerconfigjson|kubernetes.io/dockerconfigjson>",
metadata: {
namespace: namespace.metadata.name
},
stringData: {
".dockerconfigjson": config
.requireSecret("docker-hub-token")
.apply(value => {
return JSON.stringify({
auths: {
"<https://index.docker.io/v1/>": {
auth: value
}
}
})
})
}
});
Output:
kubectl get secret dockerprivatepull-s2nimzmf --namespace=apps --output=yaml master ● ↓2 10:43:53
apiVersion: v1
data:
.dockerconfigjson: eyJhdXRocyI6eyJodHRwczovL2luZGV4LmRvY2tlci5pby92MS8iOnsiYXV0aCI6ImRlOWM1NTgyLTM4ZTMtNGY1Mi04ZTFhLTk0NzgzNWQ2ZTc5YyJ9fX0=
kind: Secret
metadata:
annotations:
<http://kubectl.kubernetes.io/last-applied-configuration|kubectl.kubernetes.io/last-applied-configuration>: |
{"apiVersion":"v1","kind":"Secret","metadata":{"annotations":{"<http://pulumi.com/autonamed|pulumi.com/autonamed>":"true"},"labels":{"<http://app.kubernetes.io/managed-by|app.kubernetes.io/managed-by>":"pulumi"},"name":"dockerprivatepull-s2nimzmf","namespace":"apps"},"stringData":{".dockerconfigjson":"{\"auths\":{\"<https://index.docker.io/v1/>\":{\"auth\":\"<clear text secret here!!!>"}}}"},"type":"<http://kubernetes.io/dockerconfigjson|kubernetes.io/dockerconfigjson>"}
<http://pulumi.com/autonamed|pulumi.com/autonamed>: "true"
creationTimestamp: "2020-01-28T09:43:00Z"
labels:
<http://app.kubernetes.io/managed-by|app.kubernetes.io/managed-by>: pulumi
name: dockerprivatepull-s2nimzmf
namespace: osimis
resourceVersion: "935549"
selfLink: /api/v1/namespaces/osimis/secrets/dockerprivatepull-s2nimzmf
uid: c19731a4-45e9-414a-8a04-fb92ce5f05bd
type: <http://kubernetes.io/dockerconfigjson|kubernetes.io/dockerconfigjson>
limited-rainbow-51650
01/28/2020, 9:50 AMkubectl
, the whole annotation isn’t there (as it should be)purple-coat-77714
01/28/2020, 5:11 PMerror: configured Kubernetes cluster is unreachable: unable to load schema information from the API server: Get https://<DIFFERENT_IP_THAN_CLUSTER>/openapi/v2?timeout=32s: dial tcp <DIFFERENT_IP_THAN_CLUSTER>:443: i/o timeout
. It seems like I’m missing a step, did anyone encounter this before?millions-judge-24978
01/28/2020, 11:33 PM0.18.19
release inadvertently?bitter-dentist-28132
01/29/2020, 6:10 PMable-crayon-21563
01/29/2020, 9:37 PMSecret
resource, to be used as a pulumi.Input<>
in my program? (without using stack references)hundreds-receptionist-31352
01/30/2020, 12:14 PMhundreds-receptionist-31352
01/30/2020, 12:14 PMbetter-rainbow-14549
01/30/2020, 12:28 PMbetter-rainbow-14549
01/30/2020, 12:29 PMhundreds-receptionist-31352
01/30/2020, 12:32 PMbetter-rainbow-14549
01/30/2020, 12:34 PMbetter-rainbow-14549
01/30/2020, 12:35 PMhundreds-receptionist-31352
01/30/2020, 12:38 PMhundreds-receptionist-31352
01/30/2020, 3:30 PMhundreds-receptionist-31352
01/30/2020, 3:30 PMhundreds-receptionist-31352
01/30/2020, 3:30 PMbreezy-photographer-54783
01/30/2020, 5:57 PMgorgeous-egg-16927
02/04/2020, 6:29 PMhundreds-restaurant-18469
02/09/2020, 7:40 PMadamant-intern-63433
02/09/2020, 8:57 PMlimited-rainbow-51650
02/10/2020, 1:46 PMdocker-hub-token
and refer to it from my deployment, I get an error:
Failed to pull image "<my private image name here>": illegal base64 data at input byte 8
Am I still missing something?gorgeous-egg-16927
02/10/2020, 4:18 PMable-crayon-21563
02/11/2020, 1:56 AMk8s.Provider
that I supply to those resources is being flagged as changing. For example:
├─ kubernetes:core:Namespace foobar replace [diff: ~provider]
Seems the provider urn is changing:
[provider: urn:pulumi:proto::example::pulumi:providers:kubernetes::cluster-proto::35fb4c9f-c17e-4685-9459-ad432be24927 => urn:pulumi:proto::example::pulumi:providers:kubernetes::cluster-proto::f0e50e3c-7584-479a-bf2f-484379ca4f24]
To be clear, the program flow is to create a GKE cluster, synthesize a kubeconfig, create a Provider
based on it, and then create a Namespace
with {provider: ...}
.hundreds-portugal-17080
02/12/2020, 6:33 AMhundreds-portugal-17080
02/12/2020, 6:44 AMable-crayon-21563
02/12/2020, 5:25 PMprovider
in the ConfigFile
. It seems to use the ambient kube provider.able-crayon-21563
02/12/2020, 5:25 PMprovider
in the ConfigFile
. It seems to use the ambient kube provider.ConfigFile
to the mix.gorgeous-egg-16927
02/12/2020, 5:58 PMable-crayon-21563
02/12/2020, 5:59 PMpulumi.ComponentResource
to wrap the ConfigFile
. i.e. provider
is set on the ComponentResource
, and the ConfigFile
simply uses parent
. Could that be it?gorgeous-egg-16927
02/12/2020, 6:02 PMable-crayon-21563
02/12/2020, 6:04 PMgorgeous-egg-16927
02/12/2020, 6:10 PMexport class TestComponentResource extends pulumi.ComponentResource {
constructor(name: string,
opts: pulumi.ComponentResourceOptions = {}) {
super("test:kubernetes-ts:TestComponentResource", name, {}, opts);
new k8s.yaml.ConfigFile("guestbook",
{file: "guestbook.yaml"}, {parent: this}
);
}
}
new TestComponentResource("test", {provider: gkeCluster.provider});
able-crayon-21563
02/12/2020, 6:16 PMparent
set on the provider; I had dependsOn
.gorgeous-egg-16927
02/12/2020, 6:17 PM