https://pulumi.com logo
Title
t

tall-crowd-93084

10/20/2022, 3:45 PM
Hey everyone, kick pulumi's tyres for the first time today. I'm sure this is a version thing, but I can't get the types to line up with some
tf2pulumi
code... Even the example code here: https://www.pulumi.com/registry/packages/hcloud/api-docs/servernetwork/ isn't working. Details in the thread so as not to pollute the channel edit, sorry - I've just seen greetbot's note about #typescript
const node1 = new hcloud.Server("node1", {
    image: "debian-9",
    serverType: "cx11",
});
const mynet = new hcloud.Network("mynet", {ipRange: "10.0.0.0/8"});
const foonet = new hcloud.NetworkSubnet("foonet", {
    networkId: mynet.id,
    type: "cloud",
    networkZone: "eu-central",
    ipRange: "10.0.1.0/24",
});
const srvnetwork = new hcloud.ServerNetwork("srvnetwork", {
    serverId: node1.id,
    networkId: mynet.id,
    ip: "10.0.1.5",
});
I'm getting errors like
Type 'Output<string>' is not assignable to type 'Input<number>'.
anywhere I'm trying to pass ids like
networkId: mynet.id
I tracked down: https://github.com/pulumi/pulumi-hcloud/issues/63 so I assume from this that no one's using pulumi with hetzner?
I can conform that the
.apply(parseInt)
trick mentioned there seems to work 🙂