Last active
July 13, 2018 05:34
-
-
Save t3yamoto/933e110a5d9bdb2fab44c87171015f26 to your computer and use it in GitHub Desktop.
serverless-app-guide5-4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.python-version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
STACK_NAME="your-stack-name" | |
REGION="ap-northeast-1" | |
aws cloudformation create-stack \ | |
--stack-name ${STACK_NAME} \ | |
--region ${REGION} \ | |
--template-body file://userpool-template.yaml \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
STACK_NAME="your-stack-name" | |
REGION="ap-northeast-1" | |
aws cloudformation describe-stacks \ | |
--stack-name ${STACK_NAME} \ | |
--region ${REGION} \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Resources: | |
UserPool: | |
Type: 'AWS::Cognito::UserPool' | |
Properties: | |
Schema: | |
- Name: 'email' | |
StringAttributeConstraints: | |
MinLength: '0' | |
MaxLength: '2048' | |
Required: true | |
AttributeDataType: 'String' | |
Mutable: true | |
AdminCreateUserConfig: | |
AllowAdminCreateUserOnly: true | |
AliasAttributes: ['email'] | |
AutoVerifiedAttributes: ['email'] | |
EmailVerificationSubject: 'Your verification code' | |
EmailVerificationMessage: 'Your verification code is {####}.' | |
MfaConfiguration: 'OFF' | |
UserPoolName: | |
Ref: AWS::StackName | |
Policies: | |
PasswordPolicy: | |
RequireLowercase: false | |
RequireSymbols: false | |
RequireNumbers: false | |
MinimumLength: 6 | |
RequireUppercase: false | |
UserPoolClient: | |
Type : "AWS::Cognito::UserPoolClient" | |
Properties: | |
ClientName: 'client-app-name' | |
GenerateSecret: false | |
UserPoolId: !Ref UserPool | |
Outputs: | |
UserPoolId: | |
Value: !Ref UserPool | |
UserPoolClientId: | |
Value: !Ref UserPoolClient | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment