narrow-cpu-35517
09/29/2022, 6:07 AMconst deployment = new k8s.apps.v1.Deployment(
"deployment-game",
{
metadata: { name: "deployment-game", namespace: namespaceName },
spec: {
replicas: 5,
selector: { matchLabels: { app: "2048" } },
template: {
metadata: { labels: { app: "2048" } },
spec: {
containers: [
{
image: `<http://xxxx.dkr.ecr.us-east-1.amazonaws.com/web-bff-d3f46e7:latest|xxxx.dkr.ecr.us-east-1.amazonaws.com/web-bff-d3f46e7:latest>`,
imagePullPolicy: "Always",
name: "2048",
ports: [{ containerPort: 80 }],
},
],
},
},
},
},
{ provider }
);
narrow-cpu-35517
09/29/2022, 6:07 AMbulky-rose-70012
09/29/2022, 7:04 AMcomment-on-pr: true
and diff: true
.enough-table-42729
09/29/2022, 7:18 AMVpc.fromExistingIds
by passing the existing vpc id, but it doesn't seem to populate the publicSubnetIds
and publicSubnetIds
fields of the resulting object. aws.ec2.getVpc
or aws.ec2.getSubnets
don't distinguish between public and private subnets. Am I missing something obvious? Is there some other way to do it?
The existing VPC and subnets should not be managed by the stack that is creating the clusters.
Thanks.lively-france-83054
09/29/2022, 8:26 AMbrash-restaurant-84207
09/29/2022, 11:31 AMbig-psychiatrist-43588
09/29/2022, 12:15 PMthousands-engineer-52020
09/29/2022, 2:00 PMConfig
object with various getters and setters for retrieving values." https://www.pulumi.com/docs/intro/concepts/config/ But I can't find any setter in the API documentationaverage-printer-31589
09/29/2022, 2:30 PMred-table-91012
09/29/2022, 2:44 PMcreamy-window-21036
09/29/2022, 6:11 PMproject_settings=auto.ProjectSettings(
name=project_name,
runtime="python",
backend={"url": "<s3://bucket-in-different-region-or-other-account>"})
stack = auto.create_or_select_stack(stack_name=stack_name,
project_name=project_name,
program=pulumi_program,
opts=auto.LocalWorkspaceOptions(project_settings=project_settings,
secrets_provider=secrets_provider}))
I am using pulumi_eks to provision a cluster
import pulumi_eks as eks
eks.Cluster(...)
Is there a way to to pass seperate credential to both of the context?
I mean separate creds for pulumi login and separate creds to provision EKS clusterfierce-xylophone-92490
09/29/2022, 7:11 PMbrash-restaurant-84207
09/29/2022, 8:02 PMthankful-king-67661
09/29/2022, 11:10 PMthankful-king-67661
09/29/2022, 11:10 PMthankful-king-67661
09/29/2022, 11:11 PMAZURE_EXISTING_CONTAINER_REGISTRY_ID = config.require_secret("AZURE_EXISTING_CONTAINER_REGISTRY_ID")
thankful-king-67661
09/29/2022, 11:11 PMthankful-king-67661
09/29/2022, 11:12 PMopts=ResourceOptions(
import_=AZURE_EXISTING_CONTAINER_REGISTRY_ID,
retain_on_delete=True,
protect=True
)
thankful-king-67661
09/29/2022, 11:12 PM.apply
method as well but it does not workthankful-king-67661
09/29/2022, 11:13 PMthankful-king-67661
09/29/2022, 11:13 PMreq = resource_pb2.RegisterResourceRequest(
TypeError: bad argument type for built-in operation
thankful-king-67661
09/29/2022, 11:13 PMfierce-xylophone-92490
09/30/2022, 2:55 AMgit push ...
. But those files wouldn't be tracked by the pulumi state. Would this work? Or would pulumi freak out if I try to do pulumi destroy
on the drifted repo later?
I'd love any resources that show someone trying to accomplish something similarflaky-arm-38472
09/30/2022, 7:13 AMcp: cannot open 'pulumi.X3wA11JaNP/pulumi/./pulumi-language-yaml' for reading: Permission denied
cp: cannot open 'pulumi.X3wA11JaNP/pulumi/./pulumi-language-nodejs' for reading: Permission denied
cp: cannot open 'pulumi.X3wA11JaNP/pulumi/./pulumi-language-python' for reading: Permission denied
cp: cannot open 'pulumi.X3wA11JaNP/pulumi/./pulumi-language-dotnet' for reading: Permission denied
cp: cannot open 'pulumi.X3wA11JaNP/pulumi/./pulumi-language-java' for reading: Permission denied
cp: cannot open 'pulumi.X3wA11JaNP/pulumi/./pulumi-language-go' for reading: Permission denied
And all the new projects get this:
error: failed to load language plugin go: Could not automatically download and install language plugin 'pulumi-language-go', install the plugin using `pulumi plugin install language go`.
Underlying error: 404 HTTP error fetching plugin from <https://api.github.com/repos/pulumi/pulumi-go/releases/latest>. If this is a private GitHub repository, try providing a token via the GITHUB_TOKEN environment variable. See: <https://github.com/settings/tokens>
Running above command still throws the same error 404adorable-butcher-51503
09/30/2022, 8:15 AMadorable-butcher-51503
09/30/2022, 8:16 AMadorable-butcher-51503
09/30/2022, 8:18 AMimport pulumi
from pulumi_aws import s3
import pulumi
import pulumi_aws as aws
# Create an AWS resource (S3 Bucket)
bucket = s3.Bucket('my-bucket')
# Export the name of the bucket
pulumi.export('bucket_name', bucket.id)
size = 't2.micro'
ami = aws.get_ami(most_recent="true",
owners=[""],
filters=[{"name":"name","values":["amzn-ami-hvm-*"]}])
group = aws.ec2.SecurityGroup('webserver-secgrp',
description='Enable HTTP access',
ingress=[
{ 'protocol': 'tcp', 'from_port': 22, 'to_port': 22, 'cidr_blocks': ['0.0.0.0/0'] },
{ 'protocol': 'tcp', 'from_port': 80, 'to_port': 80, 'cidr_blocks': ['0.0.0.0/0'] }
])
user_data = """
#!/bin/bash
echo "Hello, World!" > index.html
nohup python -m SimpleHTTPServer 80 &
"""
server = aws.ec2.Instance('webserver-www',
instance_type=size,
vpc_security_group_ids=[group.id], # reference security group from above
user_data=user_data,
ami=ami.id)
pulumi.export('publicIp', server.public_ip)
pulumi.export('publicHostName', server.public_dns)
busy-dentist-99842
09/30/2022, 2:08 PMconfig
in a custom Pulumi template. It seems default
can't handle an object for aws:defaultTags
.
Here is my Pulumi.yaml
in the template
name: ${PROJECT}
description: ${DESCRIPTION}
runtime: nodejs
stackConfigDir: config/
template:
description: A minimal AWS TypeScript Pulumi program
config:
aws:defaultTags:
default:
tags:
Tag1: value1
Tag2: value2
aws:region:
description: The AWS region to deploy into
default: us-east-1
I run the pulumi new
command and get the following error
$ pulumi new ~/dev/rs-pulumi-templates/aws-typescript --name sandbox --stack sandbox --yes
error: yaml: unmarshal errors:
line 10: cannot unmarshal !!map into string
The behavior I expect is to get a Pulumi project created with this in the Pulumi.sandbox.yaml
encryptionsalt: v1:X5f2X+HrmBA=:v1:W4AbC74tERwws/44:W9KutY3Gg2o7xh4sMr//DrIeCmj+lQ==
config:
aws:region: us-east-1
aws:defaultTags:
tags:
Tag1: value1
Tag2: value2
I was able to get the configurations I want by running pulumi new
with the --config-path
and --config
flags. I was also able to get the expected result using the pulumi config
command.
Ideally, I'd like to get the expected outcome from the template, not the command line. Any ideas on what I am doing wrong or if it is even possible?
Thanksaverage-tiger-58107
09/30/2022, 3:28 PMprocess.env
(node)?future-journalist-90839
09/30/2022, 4:40 PM