【发布时间】:2015-04-06 00:24:25
【问题描述】:
我正在尝试将我的 Python Flask 应用程序部署到 Elastic Beanstalk 并在配置文件中创建一个 DynamoDB 表和 SQS 队列。我已经像这样设置了我的配置文件(类似于https://github.com/awslabs/eb-py-flask-signup/blob/master/.ebextensions/setup.config):
Resources:
EmailsTable:
Type: AWS::DynamoDB::Table
Properties:
KeySchema:
HashKeyElement:
AttributeName: "email"
AttributeType: "S"
ProvisionedThroughput:
ReadCapacityUnits: 1
WriteCapacityUnits: 1
NewBatchQueue:
Type: "AWS::SQS::Queue"
files:
"/var/app/app.config":
mode: "000444"
owner: "apache"
group: "apache"
content: |
AWS_REGION = '`{ "Ref" : "AWS::Region"}`'
EMAIL_TABLE = '`{ "Ref" : "EmailsTable"}`'
option_settings:
"aws:elasticbeanstalk:application:environment":
"APP_CONFIG": "/var/app/app.config"
我已将默认角色策略设置为接受 DynamoDB(即通过允许 dynamodb:"*"),但是当我使用 git aws.push 推送时,我的 AWS 控制台上出现以下错误:Service:AmazonCloudFormation, Message:Stack named 'awseb-e-79sqgmxq6p-stack' aborted operation. Current state: 'UPDATE_ROLLBACK_IN_PROGRESS' Reason: The following resource(s) failed to create: [EmailsTable].
对于为什么会发生这种情况有什么想法吗?
【问题讨论】:
标签: python amazon-web-services flask amazon-elastic-beanstalk amazon-dynamodb