Elastic Beanstalk错误地使用Python 2.7而不是3.7部署环境
在运行Elastic Beanstalk错误地使用Python 2.7而不是3.7部署环境,python,amazon-web-services,amazon-elastic-beanstalk,Python,Amazon Web Services,Amazon Elastic Beanstalk,在运行ebinit之后,我选择了一个使用Python 3.7和AL 2的环境。这是生成的配置文件: branch-defaults: default: environment: django-env group_suffix: null global: application_name: dashboard branch: null default_ec2_keyname: aws-eb default_platform: Python 3.7 running
ebinit
之后,我选择了一个使用Python 3.7和AL 2的环境。这是生成的配置文件:
branch-defaults:
default:
environment: django-env
group_suffix: null
global:
application_name: dashboard
branch: null
default_ec2_keyname: aws-eb
default_platform: Python 3.7 running on 64bit Amazon Linux 2
default_region: us-west-2
include_git_submodules: true
instance_profile: null
platform_name: null
platform_version: null
profile: eb-cli
repository: null
sc: null
workspace_type: Application
很明显,我应该在EC2实例中使用python 3.7,但事实似乎并非如此
当我SSH到实例中并运行
python
时,实例的默认值是2.7。这里怎么了?您必须使用python3
而不是python
python3 -V
Python 3.7.6
但是
python -V
Python 2.7.16