better-shampoo-48884
05/19/2021, 6:52 AMurn:pulumi:mystack::myproject::purpose:components:provider$purpose:components:group$purpose:components:k8s$azure-native:containerservice:ManagedCluster$random:index/randomUuid:RandomUuid::mystack-cluster-k8s-location-diskcrypto-to-kv-cert-RA
I'm guessing the :components:k8s$azure-native:
bit is what's going to change.
Initial thought: export the stack + search and replace + reimport stack? Any other ideas? Doing pulumi import
on each one is.. just not going to work, besides taking a huge amount of time, it will just be really really really tricky to ensure I have the right URN specified for each resource.brash-country-7541
05/19/2021, 8:22 AMrough-arm-38844
05/19/2021, 8:55 AMquiet-truck-58459
05/19/2021, 12:52 PMget_registry_image
from the pulumi docker package with a private image?
I'm basically trying to follow the example in the docs
import pulumi
import pulumi_docker as docker
ubuntu_registry_image = docker.get_registry_image(name="<<private image name>>")
ubuntu_remote_image = docker.RemoteImage("ubuntuRemoteImage",
name=ubuntu_registry_image.name,
pull_triggers=[ubuntu_registry_image.sha256_digest])
but get a Forbidden error
Exception: invoke of docker:index/getRegistryImage:getRegistryImage failed: invocation of docker:index/getRegistryImage:getRegistryImage returned an error: invoking docker:index/getRegistryImage:getRegistryImage: Got error when attempting to fetch image version from registry: Got bad response from registry: 403 Forbidden
quiet-truck-58459
05/19/2021, 1:57 PMimport time
import pulumi
import pulumi_docker as docker
alpine_remote_image = docker.RemoteImage("alpineRemoteImage",
name="alpine:latest",
pull_triggers=[str(time.time())]
)
little-market-63455
05/19/2021, 3:03 PMPromise<T>
s, `Input<T>`s and Output<s>
1. If I am builI am building a ComponentResource
which needs some information about an IAM user (which is already created)
2. To fetch information about that user, I can use aws.iam.getUser
which returns a Promise<GetUserResult>
3. Now, I don't know how to properly deal with that Promise
4. On one hand, I could make the ComponentResrouce accept Input<GetUserResult>
and wrap my Promise with an Output<T>
then pass it on. This should trigger dependency tracking according to my understanding. Is this really the way to go?
5. Or I could await
the promise and get the result then pass it as a regular object but then I have to enable top-level awaits or perhaps use then
?
Sorry for the confusion, trying to learn and apply too many things at the same time and I appreciate your help.limited-eve-38521
05/19/2021, 4:15 PMpulumi up
the pulumi-resource-aws
plugin was present in the path below as expected, but got not found error for 4.5.0
. Forcing 4.3.1 solved the error below:
Diagnostics:
pulumi:providers:aws (default_4_5_0):
error: could not read plugin [/Users/jeremywest/.pulumi/plugins/resource-aws-v4.5.0/pulumi-resource-aws] stdout: EOF
Deleted .pulumi folder and node_modules folder with fresh installs to try and troubleshoot but haven't looking into further since 4.3.1 doesn't have the issue.colossal-australia-65039
05/19/2021, 7:36 PMgentle-monitor-55086
05/19/2021, 8:20 PM"if servers < desired { // deploy ec2}"
With the issue being on the second run pulumi would see we didn't define the first set of ec2's and go "oh well i should destroy those". My issue was that i was generating unique values for the ec2, storing it in the userdata, and then also saving those off to a DB... So even using protect
or ignoreChanges
it was (is) a pain to try and avoid re-generating / saving new values into the DB and required all sorts of shims and "clever"(breaks if you breathe on it) code.
I don't currently have an idea about the api and would like to do it the "right" wayambitious-father-68746
05/19/2021, 11:03 PMpulumi.ResourceOptions
. Unfortunately Pulumi wants to destroy the resources that I already have. Is there a way to move resources from the default Provider configuration to a new one?sticky-bear-14421
05/20/2021, 6:53 AM--suppress-outputs
to pulumi runs? Apart from the definition of an alias like pu="pulumi up --suppress-outputs <maybe other options>"bland-army-56447
05/20/2021, 7:09 AMtfbridge
to use an existing TF Module in Pulumi.
I already “bridged” the module and generated the SDK.
Then I did go get <http://github.com/|github.com/>...
to install (?) my custom provider.
But when running pulumi up
I’m stuck with error: no resource plugin 'lxd' found in the workspace or on your $PATH
Do I additionally have to install my resource provider through pulumi plugin install
somehow? If yes, how do create the tarball needed for the installation? 🤔better-shampoo-48884
05/20/2021, 7:11 AMprovider
to a ComponentResource, will the underlying resources implicitly use that provider?
I.e. I have a ComponentResource "network" - that creates azure-vnet, azure-subnet(s) and azure-networksecuritygroups - if I pass the provider to the "network" componentresource, will the vnet, subnets, and nsg's be created with that provider?rhythmic-activity-46295
05/20/2021, 4:50 PMfull-dress-10026
05/20/2021, 4:54 PMaws.lambda.CallbackFunction
and just added tslog to my package json. Upon adding it and calling log.info in my code, I get the following error during the pulumi preview.
function 'callback': batchScalingManager.ts(190,31): referenced
function 'handleBatch': batchScalingManager.ts(25,20): which captured
variable 'log' which indirectly referenced
function 'wrapCallSite': source-map-support.js(348,21): which referenced
function 'isInBrowser': source-map-support.js(50,20): which could not be serialized because
Unexpected missing variable in closure environment: window
Function code:
function isInBrowser() {
if (environment === "browser")
return true;
if (environment === "node")
return false;
...
Is this something that could be fixed from my end or no dice with this lib?mysterious-lighter-33699
05/20/2021, 5:16 PMpulumi stack init project/$USER --copy-config-from project/staging
"forget" configuration values after about a day. That is, pulumi up in that stack no longer can find config settings that are set for the staging stack. This happens after a few hours. Right after creating the personal stack, I can use those variables. The next workday, the variables are gone.
We use an AWS SSO provider for our API credentials. Might expiration on those creds cause pulumi stack config to get dropped?gorgeous-minister-41131
05/20/2021, 7:48 PMaws:ec2:LaunchTemplate (ci-kiam-server):
error: 1 error occurred:
* updating urn:pulumi:ci::aws-eks-py::aws:ec2/launchTemplate:LaunchTemplate::ci-kiam-server: 1 error occurred:
* error modifying Launch Template (lt-0f0da90e33e334f78): InvalidParameterValue: Invalid launch template version: either '$Default', '$Latest', or a numeric version are allowed.
gorgeous-minister-41131
05/20/2021, 7:49 PMgorgeous-minister-41131
05/20/2021, 7:49 PMuser_data=user_data_b64,
update_default_version=True,
gorgeous-minister-41131
05/20/2021, 8:00 PMambitious-salesmen-39356
05/20/2021, 9:12 PMPreview failed: error constructing backend state manager: Remote workspace Terraform version "0.14.7" does not match local Terraform version "0.15.3"
Is it possible to configure the NewRemoteStateReference
to use a specific terraform version in order to match our state?echoing-zebra-28421
05/20/2021, 10:55 PMpulumi.yaml
?
I have variables in an .env file but when I run pulumi up
those variables are not uploaded.colossal-australia-65039
05/20/2021, 11:58 PMimport { getSecretVersion, getSecret } from "@pulumi/aws/secretsmanager"
getSecret({ name: "somesecret" }).then((s) => getSecretVersion({ secretId: s.arn }).then((sv) => sv.secretString))
bored-table-20691
05/21/2021, 1:01 AMtls
provider?bored-monitor-99026
05/21/2021, 4:52 AMpurple-lawyer-35555
05/21/2021, 7:39 AMlittle-market-63455
05/21/2021, 1:55 PMOutputInstance.get()
method. From the docs:
This function is only callable in code that runs in the cloud post-deployment. At this point all Output values will be known and can be safely retrieved.But at 'cloud' time the Pulumi packages aren't available, for example for serialized lambdas. What am I missing? Is there any use case for it?
bored-table-20691
05/21/2021, 4:31 PMbored-table-20691
05/21/2021, 4:42 PMcolossal-australia-65039
05/21/2021, 10:13 PM@pulumi/docker
to build an image and i always get this warning. Why is it a warning?
warning: #1 [internal] load build definition from Dockerfile
colossal-australia-65039
05/21/2021, 10:13 PM@pulumi/docker
to build an image and i always get this warning. Why is it a warning?
warning: #1 [internal] load build definition from Dockerfile
faint-whale-59078
05/22/2021, 4:54 AMcolossal-australia-65039
05/24/2021, 5:52 PMconst repo = new Repository("logfiles", {
name: `repo/name`,
})
const gitCommitSha = execSync("git rev-parse HEAD").toString().trim()
export const image = new docker.Image("image", {
imageName: interpolate`${repo.repositoryUrl}:${gitCommitSha}`,
build: {
context: `../`,
dockerfile: `../Dockerfile`,
},
})
the Dockerfile is pretty simple
FROM node:16-alpine
WORKDIR /code
COPY package.json package-lock.json ./
RUN npm install
COPY . .
ENTRYPOINT ["npm", "run", "start"]
package.json versions
"@pulumi/docker": "^3.0.0",
"@pulumi/pulumi": "^3.0.0",
pulumi version
v3.3.0