forked from ucloud-web/python-sdk
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathREADME
More file actions
32 lines (23 loc) · 902 Bytes
/
README
File metadata and controls
32 lines (23 loc) · 902 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#ucloud 内存 磁盘空间监控脚本试用方法
#监控脚本使用 ucloud 提供短信包服务请先购买短信包否则无法接收短信
1. sendsms.py 短信发送脚本
1. mem.py 监控内存使用情况示范
2. disk.py 监控磁盘使用情况示范
#使用方法
打开 cp config.simple.py config.py 修改以下配置
#配置公私钥 公私钥请到用户中心获取
# public_key = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
# private_key = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
#
#配置api地址'''
# 无外网IP主机使用
# base_url = "http://api.int.ucloud.cn"
#
# 有外网IP主机使用
# base_url = "http://api.ucloud.cn"
#
sendsms.py 使用示范
python sendsms.py 13777777777 测试短信
#监控脚本示范建议加入crontab 1分钟一次
#
# api_demo.py 中有常用的 主机相关操作和 修改 ulb backend API