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!

2 Risposte
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

con risposta 2 anni fa
0
Risposta accettata

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
con risposta 2 anni fa

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande