Associate the principal to the portfolio and apply command completes with success.
Actual Behavior
Getting aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [50s elapsed] Indefinitely
Principal successfully gets associated, but apply won't complete.
Relevant Error/Panic Output Snippet
aws_servicecatalog_principal_portfolio_association.principal_arn: Creating...
aws_iam_role_policy.service_catalog: Modifying... [id=ServiceCatalogEndUserRole:ServiceCatalogEndUserPolicy]
aws_iam_role_policy.service_catalog: Modifications complete after 1s [id=ServiceCatalogEndUserRole:ServiceCatalogEndUserPolicy]
aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [10s elapsed]
aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [20s elapsed]
aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [30s elapsed]
aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [40s elapsed]
aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [50s elapsed]
aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [1m0s elapsed]
aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [1m10s elapsed]
^C
Terraform Configuration Files
Note* i only added the applicable snippet. Code requires an s3 bucket with cfn template in it
Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.
Volunteering to Work on This Issue
If you are interested in working on this issue, please leave a comment.
If this would be your first contribution, please review the contribution guide.
Terraform Core Version
1.9.8
AWS Provider Version
5.76.0
Affected Resource(s)
resource "aws_servicecatalog_principal_portfolio_association"
Expected Behavior
Associate the principal to the portfolio and apply command completes with success.
Actual Behavior
Getting aws_servicecatalog_principal_portfolio_association.principal_arn: Still creating... [50s elapsed] Indefinitely Principal successfully gets associated, but apply won't complete.
Relevant Error/Panic Output Snippet
Terraform Configuration Files
Note* i only added the applicable snippet. Code requires an s3 bucket with cfn template in it
resource "aws_servicecatalog_portfolio" "demo" { name = "Demo Portfolio" description = "Portfolio containing EC2 products" provider_name = "IT Team" }
resource "aws_servicecatalog_product" "ec2" { name = "Simple EC2 Instance" owner = "IT Team" description = "Launches a simple EC2 instance" type = "CLOUD_FORMATION_TEMPLATE"
provisioning_artifact_parameters { name = "v1.0" description = "Initial version" disable_template_validation = true type = "CLOUD_FORMATION_TEMPLATE" template_url = "https://s3.amazonaws.com/${aws_s3_bucket.service_catalog.id}/${aws_s3_object.ec2.key}" } }
resource "aws_servicecatalog_product_portfolio_association" "demo" { portfolio_id = aws_servicecatalog_portfolio.demo.id product_id = aws_servicecatalog_product.ec2.id }
resource "aws_servicecatalog_principal_portfolio_association" "principal_arn" { portfolio_id = aws_servicecatalog_portfolio.demo.id principal_arn = var.principal_arn principal_type = "IAM" }
resource "aws_servicecatalog_constraint" "demo" { description = "Launch constraint for EC2 product" portfolio_id = aws_servicecatalog_portfolio.demo.id product_id = aws_servicecatalog_product.ec2.id type = "LAUNCH"
parameters = jsonencode({ "RoleArn": "${aws_iam_role.service_catalog.arn}" }) }
Steps to Reproduce
terraform apply
Debug Output
No response
Panic Output
No response
Important Factoids
No response
References
No response
Would you like to implement a fix?
None