Skip to content

Instantly share code, notes, and snippets.

@benjaminran
Created February 24, 2022 17:11
Show Gist options
  • Save benjaminran/2178459590273feb45f3ef72963dc12c to your computer and use it in GitHub Desktop.
Save benjaminran/2178459590273feb45f3ef72963dc12c to your computer and use it in GitHub Desktop.
#
# pulumi python source code
#
role = aws.iam.Role(
"ec2-ng-role-atl-pinecone-prod-us-east-1",
assume_role_policy="{\"Version\":\"2012-10-17\",\"Statement\":[{\"Effect\":\"Allow\",\"Principal\":{\"Service\":\"ec2.amazonaws.com\"},\"Action\":\"sts:AssumeRole\"}]}",
description="Role used by worker nodes in the Pinecone EKS cluster.",
force_detach_policies=False,
max_session_duration=3600,
name="pc_cluster_node_role",
path="/",
tags={
"Name": "pc_cluster_node_role",
},
opts=pulumi.ResourceOptions(protect=True))
#
# terminal output from running it
#
$ pulumi up -s pinecone/atl-pinecone-prod-us-east-1
Previewing update (pinecone/atl-pinecone-prod-us-east-1)
View Live: https://app.pulumi.com/pinecone/aws/atl-pinecone-prod-us-east-1/previews/43c3245b-bf00-4bcb-a965-a71866c2a318
Type Name Plan Info
pulumi:pulumi:Stack aws-atl-pinecone-prod-us-east-1 1 message
+- └─ aws:iam:Role ec2-ng-role-atl-pinecone-prod-us-east-1 replace
Diagnostics:
pulumi:pulumi:Stack (aws-atl-pinecone-prod-us-east-1):
Failed to resolve python version command: fork/exec /Users/benjaminran/dev/iac/pulumi/aws/venv/bin/python: no such file or directory
Outputs:
+ eksNodeRoleArn : output<string>
Do you want to perform this update? details
pulumi:pulumi:Stack: (same)
[urn=urn:pulumi:atl-pinecone-prod-us-east-1::aws::pulumi:pulumi:Stack::aws-atl-pinecone-prod-us-east-1]
++aws:iam/role:Role: (create-replacement) 🔒
[id=pc_cluster_node_role]
[urn=urn:pulumi:atl-pinecone-prod-us-east-1::aws::aws:iam/role:Role::ec2-ng-role-atl-pinecone-prod-us-east-1]
[provider=urn:pulumi:atl-pinecone-prod-us-east-1::aws::pulumi:providers:aws::default_4_37_5::87c68237-3423-4b8d-92fb-f66d002d4ddf]
+ assumeRolePolicy : "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Effect\":\"Allow\",\"Principal\":{\"Service\":\"ec2.amazonaws.com\"},\"Action\":\"sts:AssumeRole\"}]}"
+ description : "Role used by worker nodes in the Pinecone EKS cluster."
+ forceDetachPolicies: false
+ maxSessionDuration : 3600
+ name : "pc_cluster_node_role"
+ path : "/"
+ tags : {
+ Name : "pc_cluster_node_role"
}
+-aws:iam/role:Role: (replace) 🔒
[id=pc_cluster_node_role]
[urn=urn:pulumi:atl-pinecone-prod-us-east-1::aws::aws:iam/role:Role::ec2-ng-role-atl-pinecone-prod-us-east-1]
[provider=urn:pulumi:atl-pinecone-prod-us-east-1::aws::pulumi:providers:aws::default_4_37_5::87c68237-3423-4b8d-92fb-f66d002d4ddf]
- arn : "arn:aws:iam::375450313109:role/pc_cluster_node_role"
- createDate : "2022-02-22T23:21:15Z"
- id : "pc_cluster_node_role"
- inlinePolicies : [
- [0]: {
}
]
- managedPolicyArns : [
- [0]: "arn:aws:iam::375450313109:policy/pc_cluster_node_access"
- [1]: "arn:aws:iam::375450313109:policy/pc_cert_manager_access"
- [2]: "arn:aws:iam::aws:policy/AmazonEKS_CNI_Policy"
- [3]: "arn:aws:iam::aws:policy/AmazonEKSWorkerNodePolicy"
]
- namePrefix : ""
- uniqueId : "AROAVO2UVEGKXDMQOU7LQ"
--outputs:--
+ eksNodeRoleArn : output<string>
<<aws:iam/role:Role: (discard-replaced)
[id=pc_cluster_node_role]
[urn=urn:pulumi:atl-pinecone-prod-us-east-1::aws::aws:iam/role:Role::ec2-ng-role-atl-pinecone-prod-us-east-1]
[provider=urn:pulumi:atl-pinecone-prod-us-east-1::aws::pulumi:providers:aws::default_4_37_5::87c68237-3423-4b8d-92fb-f66d002d4ddf]
Do you want to perform this update? no
confirmation declined, not proceeding with the update
warning: A new version of Pulumi is available. To upgrade from version '3.22.1' to '3.24.1', run
$ brew upgrade pulumi
or visit https://pulumi.com/docs/reference/install/ for manual instructions and release notes.
#
# versions
#
$ pip list
Package Version
------------------ ---------
Arpeggio 1.10.2
attrs 21.4.0
certifi 2021.10.8
charset-normalizer 2.0.12
dill 0.3.4
grpcio 1.44.0
idna 3.3
parver 0.3.1
pip 22.0.3
protobuf 3.19.4
pulumi 3.25.0
pulumi-aws 4.37.5
pulumi-eks 0.37.1
pulumi-kubernetes 3.16.0
PyYAML 6.0
requests 2.27.1
semver 2.13.0
setuptools 60.9.3
six 1.16.0
urllib3 1.26.8
wheel 0.37.1
$ pulumi version
v3.22.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment