deploy opensearch with cognito auth without manual intervention (terraform)

0

Hi,

ive created a terraform module to deploy aws opensearch with cognito auth.

Then problem is that when creating the aws opensearch it needs the cognito user pool and identity pool. To create the idenity pool, i need to create a dummy client app. and when opensearch is created it creates a new client app. That is not added to identity pool mappings.

Is there any way around this? Is it a terraform problem or a cognito / opensearch problem / or finishes crossed a me problem!

preguntada hace 2 años227 visualizaciones
2 Respuestas
1

Hi,

Yes I ended up with a external data call to the aws cli to to link the opensearch created app client to idenitty pool!

thanks for the reply

respondido hace 2 años
0
Respuesta aceptada

I believe there is a known issue with Terraform provider for this. There is a workaround you might want to give a try. Use local-exec provisioner in your opensearch.tf and run an AWS CLI command to update the Cognito IdP user pool client with the one you created in your cognito.tf. "aws cognito-idp update-user-pool-client......."

Please refer to https://github.com/aws-samples/opensearch-in-vpc/blob/main/opensearch-in-vpc-module/opensearch.tf

AWS
PrasDuv
respondido hace 2 años

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas