用于将Docker映像部署到AWS ECS的帮助程序。
aeropress的Python项目详细描述
aeropress是一个用于将docker映像部署到aws ecs的cli程序。它接收的文件夹路径包括 ecs任务和服务定义,然后分别执行这些任务;
- Register ECS task definitions
- Create Cloudwatch metrics for scaling policies
- Create or update scaling policies for ECS services
- Create or update alarms on Cloudwatch
- Create or update ECS services
安装
aeropress适用于python3。
pip3 install aeropress
用法
$ aeropress --help usage: cli.py [-h] [--logging-level {debug,info,warning,error}] [--version] {deploy,clean} ... aeropress AWS ECS deployment helper positional arguments: {deploy,clean} sub-command help deploy Deploy docker image to ECS. clean Clean commands for stale entitites on AWS. optional arguments: -h, --help show this help message and exit --logging-level {debug,info,warning,error} Print debug logs --version show program's version number and exit
示例
您必须先定义了一个ECS集群。然后,可以在yaml文件中定义ecs任务和服务,并运行 aeropress带有必需的参数。
aeropress deploy --path 'example/foo.yaml' --image-url 'registry.hub.docker.com/library/python' --service-name service-foo