You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)
Issue details
When working with AWS resources you often have input parameters that are JSON formatted strings that contains the configuration for the resource. A typical example is the various IAM resources with roles and policies. Sometimes these even include Output from other resources.
In all cases, it can be nice - and a lot more readable - to inline the dictionary instead of having to use json.dumps(...), Output.apply(...) or even Output.all(...).apply(...)
A real world example
import json
from typing import Any, Mapping
import pulumi
import pulumi_random as random
from pulumi_aws import rds, ssm
def setup_rds_password_and_rotation(cluster: rds.Cluster, password: random.RandomPassword) -> None:
def make_secret_string(data: Mapping[str, Any]) -> str:
return json.dumps({
'engine': 'mysql',
'dbClusterIdentifier': 'rds-cluster',
'host': data.get('endpoint'),
'username': 'root',
'password': data.get('password')
})
param = ssm.Parameter(
'...',
name='...',
type='SecureString',
data_type='text',
value=pulumi.Output.all(endpoint=cluster.endpoint, password=password.result).apply(make_secret_string),
description="Admin password used for RDS cluster",
)
It would be so much nicer to be able to write this:
Hello!
Issue details
When working with AWS resources you often have input parameters that are JSON formatted strings that contains the configuration for the resource. A typical example is the various IAM resources with roles and policies. Sometimes these even include Output from other resources.
In all cases, it can be nice - and a lot more readable - to inline the dictionary instead of having to use json.dumps(...), Output.apply(...) or even Output.all(...).apply(...)
A real world example
It would be so much nicer to be able to write this:
As value is defined as a string, then Pulumi should automatically wait ion the result and jsonify the results..
Affected area/feature
Primarily in AWS, but something similar could also be useful in Kubernetes.
The text was updated successfully, but these errors were encountered: