Skip to content
/ aliyun Public

Base on alislb https api,modify aliyun slb

Notifications You must be signed in to change notification settings

t1ger/aliyun

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 

Repository files navigation

Base on alislb https api,modify aliyun slb

命令行解析阿里云 SLB 首先需要获取阿里云账号账号的AccessKeyID及AccessKeySecret,并将其替换至 alislb.py 文件中

然后安装阿里云的接口

#pip install aliyun-python-sdk-core-v3

#pip install aliyun-python-sdk-slb 使用说明:

[root@localhost]# ./alislb.py -h usage: alislb.py [-h] [-a | -d | -u | -g]

          instance ip weight [instance ip weight ...]

针对 SLB INSTANC 进行相关操作

positional arguments:

instance ip weight 实例 IP 权重

optional arguments:

-h, --help           show this help message and exit

-a, --add            add ecs. (e.g. --add instance ip weight)

-d, --delete         delete ecs. (e.g. --delete instance ip)

-u, --update         update ecs info. (e.g. --update instance ip weight)

-g, --get            get slb info,default all. (e.g. --get instance)

增加主机 ./alislb.py -a instance ip weight

更新权重 ./alislb.py -u instance ip weight

获取实例 ./alislb.py -g instance

删除主机 ./alislb.py -d instance ip

About

Base on alislb https api,modify aliyun slb

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages