important-sandwich-62391
07/15/2021, 1:05 AMkind-carpenter-52856
07/16/2021, 8:56 AMwooden-battery-52855
07/19/2021, 2:53 PMastonishing-gpu-28317
07/19/2021, 7:23 PMpulumi up
, regardless of what i rename my stack to: error: Duplicate resource URN '<name>'; try giving it a unique name
astonishing-dinner-89046
07/19/2021, 8:02 PMregion = aws.get_region()
user_data = f"""
#!/bin/bash
sudo systemctl start docker
$(aws ecr get-login --no-include-email --region {region})
docker pull {ecr.repository_url}:latest
~ userData: "88b7a8609501c5a4f07efd83f5a4c10be14d0405" => "\n#!/bin/bash\nsudo systemctl start docker\n$(aws ecr get-login --no-include-email --region <pulumi_aws.get_region.AwaitableGetRegionResult object at 0x10a8adb20>)\ndocker pull <pulumi.output.Output object at 0x10af258b0>:latest
cuddly-vase-11770
07/20/2021, 4:29 AMfreezing-air-90947
07/20/2021, 9:06 AMfreezing-air-90947
07/20/2021, 9:06 AMwitty-twilight-96516
07/20/2021, 2:27 PMhallowed-teacher-48474
07/20/2021, 4:38 PMhallowed-teacher-48474
07/20/2021, 4:42 PMvictorious-megabyte-32350
07/21/2021, 10:11 AMpulumi preview --supress-outputs
) adds the all output.
The step is pretty similar to the example
- uses: pulumi/actions@v3
with:
command: preview
stack-name: dev
comment-on-pr: true
github-token: ${{ env.GITHUB_TOKEN }}
work-dir: ${{ env.working-directory }}
env:
PULUMI_ACCESS_TOKEN: ${{ env.PULUMI_ACCESS_TOKEN }}
Can someone help me with this?worried-hydrogen-32482
07/21/2021, 10:20 AMworried-hydrogen-32482
07/21/2021, 12:14 PMfreezing-air-90947
07/21/2021, 3:00 PMfreezing-air-90947
07/21/2021, 3:01 PMfreezing-air-90947
07/21/2021, 3:01 PMfreezing-air-90947
07/21/2021, 3:02 PMchilly-france-92780
07/22/2021, 2:24 AMpulumi up
I got the error saying error: transport is closing
. I did the same on my older non-M1 macbook and it succeeded. Only the difference was the hardware so I wonder 😕 I chose GCP and python.mysterious-australia-14256
07/22/2021, 12:35 PMfamous-parrot-52821
07/22/2021, 3:58 PMsquare-hospital-22275
07/23/2021, 1:47 PMmodern-toothbrush-56347
07/24/2021, 10:04 AMbored-elephant-39233
07/24/2021, 9:15 PMbillions-ghost-96421
07/26/2021, 6:30 AMplay
, dev
, and prod
.
play
can contain anything - it's a place for experimentation
dev
contains dev deployments of our API (perhaps different feature/hotfix branches), other internal dev tools
prod
contains the tested version of our API
How should I be organizing my code?
1) Use a single project and create the following stacks:
<org>/<project>/prod/infra
<org>/<project>/prod/api
<org>/<project>/dev/infra
<org>/<project>/dev/api/featureX
<org>/<project>/dev/api/featureY
<org>/<project>/dev/api/bugA
<org>/<project>/dev/api/bugB
<org>/<project>/play
But then I would have to add a lot of conditional statements in my program so that they are only deployed into the right stack.
2) Use a separate project for each environment and concern. Define my API and infrastructure as separate Component Resources (https://www.pulumi.com/docs/intro/concepts/resources/#components) and 'import' them into each project.
| project | sub-project | stack |
|---------|-------------|----------|
| prod | infra | infra |
| prod | api | api |
| dev | infra | infra |
| dev | api | featureX |
| dev | api | featureY |
| dev | api | bugA |
| play | infra | infra |
| play | any | any |
I understand that projects and stacks are designed to be flexible, but I would appreciate a bit of guidance. I get the feeling that the examples in the documentation expects parity between dev and prod - you deploy this project in dev, and then deploy the same project in prod. How do you organize the code when dev and prod are somewhat different (e.g. internal tools only deployed in dev) but also somewhat similar (e.g. networking)?
Thanks in advance for any help you can provide 🙇quaint-garage-36651
07/26/2021, 11:15 AMancient-monkey-64322
07/26/2021, 4:48 PMnarrow-action-47255
07/27/2021, 4:03 PMVpcId
in the &ec2.SubnetArgs{}
and I'm not finding examples. The examples I have found in Go illustrate looking up an existing VPC, where other languages show the exact example I'm trying to accomplish. Example code follows. I have tried using different things for VpcId
such as platformVpc.ID()
(which is what I would use in ctx.Export()
) and messed with ApplyT
a bit, but I can't seem to figure out how to convert it to a string. Any help would be greatly appreciated!
// Create VPC
platformVpc, err := ec2.NewVpc(ctx, "my-awesome-vpc", &ec2.VpcArgs{
CidrBlock: pulumi.String("10.99.0.0/16"),
})
if err != nil {
return err
}
platformVpcSubnetA, err := ec2.NewSubnet(ctx, "my-awesome-subnet-a", &ec2.SubnetArgs{
VpcId: pulumi.String("I DON'T KNOW WHAT TO PUT HERE"),
CidrBlock: pulumi.String("10.99.0.0/23"),
AvailabilityZone: pulumi.StringPtr("us-east-1a"),
})
if err != nil {
return err
}
freezing-greece-4855
07/27/2021, 5:42 PMmost-father-39313
07/27/2021, 6:12 PMaws:lambda:Function (docsHandlerFunc):
error: 1 error occurred:
* error creating Lambda Function (1): ValidationException:
status code: 400, request id: 27d225ae-0642-4798-af1f-b8b86ae640d5
Some googling around indicates this happens, for example, if you provide an id rather than a proper arm for the role but that's not the case here. Is there reason to believe this documentation is wrong/incorrect?