Elastic Beanstalk - '.ebxtensions02_setup.config' - 包含无效的键:'03_wsgipass' 。

问题描述 投票:0回答:1

使用这个指南来尝试部署我的使用channels的django应用。https:/medium.com@elspanishgeek how toeploy-django-channels-2-x-on-aws-elastic-beanstalk-8621771d4ff0。

这是我的 02_setup.config

container_commands:
  00_pip_upgrade:
    command: "source /opt/python/run/venv/bin/activate && pip install --upgrade pip"
    ignoreErrors: false
  01_migrate:
    command: "django-admin.py migrate"
    leader_only: true
  02_collectstatic:
    command: "django-admin.py collectstatic --noinput"
03_wsgipass:
    command: 'echo "WSGIPassAuthorization On" >> ../wsgi.conf'

当运行 eb create django-env 我明白了。

Printing Status:
2020-06-17 16:11:36    INFO    createEnvironment is starting.
2020-06-17 16:11:38    INFO    Using elasticbeanstalk-us-west-2-041741961231 as Amazon S3 storage bucket for environment data.
2020-06-17 16:11:39    WARN    Error processing file (Skipping): '.ebextensions/02_setup.config' - Contains invalid key: '03_wsgipass'. For information about valid keys, see http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/ebextensions.html
2020-06-17 16:12:00    INFO    Created security group named: sg-09fcbd00450e2438d
2020-06-17 16:12:15    INFO    Created load balancer named: awseb-e-3-AWSEBLoa-1E8WRE8X90Q7D
2020-06-17 16:12:15    INFO    Created security group named: awseb-e-3um2qhsms9-stack-AWSEBSecurityGroup-1OH8TOJHUVWOT
2020-06-17 16:12:15    INFO    Created Auto Scaling launch configuration named: awseb-e-3um2qhsms9-stack-AWSEBAutoScalingLaunchConfiguration-7V5MPL4ZNZOG
2020-06-17 16:13:35    INFO    Created Auto Scaling group named: awseb-e-3um2qhsms9-stack-AWSEBAutoScalingGroup-6WNX8OQK3WQO
2020-06-17 16:13:35    INFO    Waiting for EC2 instances to launch. This may take a few minutes.
2020-06-17 16:13:50    INFO    Created Auto Scaling group policy named: arn:aws:autoscaling:us-west-2:041741961231:scalingPolicy:b25f0129-aec8-414c-9b64-72b95986648c:autoScalingGroupName/awseb-e-3um2qhsms9-stack-AWSEBAutoScalingGroup-6WNX8OQK3WQO:policyName/awseb-e-3um2qhsms9-stack-AWSEBAutoScalingScaleUpPolicy-N1XL34JAPA6S
2020-06-17 16:13:50    INFO    Created Auto Scaling group policy named: arn:aws:autoscaling:us-west-2:041741961231:scalingPolicy:f6eecd79-39ee-475d-b927-ed1a5dc205d5:autoScalingGroupName/awseb-e-3um2qhsms9-stack-AWSEBAutoScalingGroup-6WNX8OQK3WQO:policyName/awseb-e-3um2qhsms9-stack-AWSEBAutoScalingScaleDownPolicy-155DVPR0DTOK
2020-06-17 16:13:50    INFO    Created CloudWatch alarm named: awseb-e-3um2qhsms9-stack-AWSEBCloudwatchAlarmHigh-CPMPHOMFE9IT
2020-06-17 16:13:50    INFO    Created CloudWatch alarm named: awseb-e-3um2qhsms9-stack-AWSEBCloudwatchAlarmLow-UVP8LL57BLI4
2020-06-17 16:17:49    INFO    Successfully launched environment: django-env

有什么问题吗?03_wsgipass 命令?

python django amazon-web-services amazon-elastic-beanstalk
1个回答
0
投票

缩进03_wsgipass 是不正确的。因此,EB希望在你的配置文件中使用它作为一个新的部分,而不是作为 container_commands.

© www.soinside.com 2019 - 2024. All rights reserved.