@@ -50,6 +50,8 @@ Conditions:
5050 UsePermissionsBoundary : !Not [!Equals [!Ref PermissionsBoundary, ""]]
5151 IsDevEnvironment : !Equals [!Ref Environment, dev]
5252 IsLocalDevEnvironment : !Equals [!Ref Environment, localdev]
53+ IsNotLocalDevEnvironment : !Not
54+ - !Condition IsLocalDevEnvironment
5355 IsIntEnvironment : !Equals [!Ref Environment, integration]
5456 IsProdEnvironment : !Equals [!Ref Environment, production]
5557 IsDevLikeEnvironment : !Or [!Condition IsLocalDevEnvironment, !Condition IsDevEnvironment]
@@ -128,21 +130,33 @@ Mappings:
128130 EnvironmentConfiguration :
129131 localdev :
130132 DOMAINNAME : review-hc.localdev.account.gov.uk
133+ VcDomain : review-hc.dev.account.gov.uk
134+ ServiceDomain : review-hc.localdev.account.gov.uk
131135 HealthcheckSSMClientId : ipv-core-stub-aws-prod
132136 dev :
133137 DOMAINNAME : review-hc.dev.account.gov.uk
138+ VcDomain : review-hc.dev.account.gov.uk
139+ ServiceDomain : review-hc.dev.account.gov.uk
134140 HealthcheckSSMClientId : ipv-core-stub-aws-prod
135141 build :
136142 DOMAINNAME : review-hc.build.account.gov.uk
143+ VcDomain : review-hc.build.account.gov.uk
144+ ServiceDomain : review-hc.build.account.gov.uk
137145 HealthcheckSSMClientId : ipv-core-stub-aws-prod
138146 staging :
139147 DOMAINNAME : review-hc.staging.account.gov.uk
148+ VcDomain : review-hc.staging.account.gov.uk
149+ ServiceDomain : review-hc.staging.account.gov.uk
140150 HealthcheckSSMClientId : ipv-core-stub-aws-prod
141151 integration :
142152 DOMAINNAME : review-hc.integration.account.gov.uk
153+ VcDomain : review-hc.integration.account.gov.uk
154+ ServiceDomain : review-hc.integration.account.gov.uk
143155 HealthcheckSSMClientId : ipv-core
144156 production :
145157 DOMAINNAME : review-hc.production.account.gov.uk
158+ VcDomain : review-hc.production.account.gov.uk
159+ ServiceDomain : review-hc.production.account.gov.uk
146160 HealthcheckSSMClientId : ipv-core
147161
148162Globals :
@@ -192,6 +206,31 @@ Globals:
192206 - !Ref AWS::NoValue
193207
194208Resources :
209+ OAuth :
210+ Type : AWS::Serverless::Application
211+ Properties :
212+ Location :
213+ ApplicationId : arn:aws:serverlessrepo:eu-west-2:667736788427:applications/di-ipv-cri-oauth-common
214+ SemanticVersion : 0.4.0
215+ Parameters :
216+ AuditEventNamePrefix : IPV_HMRC_RECORD_CHECK_CRI
217+ CriIdentifier : di-ipv-cri-check-hmrc-api
218+ CriAudience : !Sub
219+ - " https://${domain}"
220+ - domain : !FindInMap [EnvironmentConfiguration, !Ref Environment, VcDomain]
221+ CriVcIssuer : !Sub
222+ - " https://${domain}"
223+ - domain : !FindInMap [EnvironmentConfiguration, !Ref Environment, VcDomain]
224+ CriPrivateApiGwName : !Sub ${AWS::StackName}-private
225+ CriPublicApiGwName : !Sub ${AWS::StackName}-public
226+ Environment : !If
227+ - IsLocalDevEnvironment
228+ - dev
229+ - !Ref Environment
230+ IPVCoreRedirectURI : https://identity.staging.account.gov.uk/credential-issuer/callback?id=nino
231+ IPVCoreStubJwksEndpoint : https://test-resources.review-hc.dev.account.gov.uk/.well-known/jwks.json
232+ LambdaVpcConfiguration : di-devplatform-deploy
233+
195234 JWKSBucketRole :
196235 Type : " AWS::IAM::Role"
197236 Properties :
@@ -1535,6 +1574,33 @@ Resources:
15351574 Value : !Ref CommonStackName
15361575 Description : The stack currently used for OAuth (common-lambdas or oauth-common). Only required for test-resources.
15371576
1577+ OAuthSessionTableName :
1578+ Type : AWS::SSM::Parameter
1579+ Condition : IsNotLocalDevEnvironment
1580+ Properties :
1581+ Name : !Sub "/common-cri/oauth-common/OAuthSessionTableName"
1582+ Value : !GetAtt OAuth.Outputs.DbSessionTableName
1583+ Type : String
1584+ Description : The OAuthSessionTableName for configuring the DynamoDB Stream table from common-lambdas
1585+
1586+ OAuthPersonIdentityTableName :
1587+ Type : AWS::SSM::Parameter
1588+ Condition : IsNotLocalDevEnvironment
1589+ Properties :
1590+ Name : !Sub "/common-cri/oauth-common/OAuthPersonIdentityTableName"
1591+ Value : !GetAtt OAuth.Outputs.DbPersonIdentityTableName
1592+ Type : String
1593+ Description : The OAuthPersonIdentityTableName for configuring the DynamoDB Stream table from common-lambdas
1594+
1595+ OAuthCustomerManagedKeyId :
1596+ Type : AWS::SSM::Parameter
1597+ Condition : IsNotLocalDevEnvironment
1598+ Properties :
1599+ Name : !Sub "/common-cri/oauth-common/OAuthCustomerManagedKeyId"
1600+ Value : !GetAtt OAuth.Outputs.DbCustomerManagedKeyID
1601+ Type : String
1602+ Description : The OAuthCustomerManagedKeyId for configuring the DynamoDB Stream table from common-lambdas
1603+
15381604
15391605# #################################################################
15401606# #
0 commit comments