Compare commits

..

1321 Commits

Author SHA1 Message Date
Zexi Li
c9b485b9f3 Merge pull request #7548 from wanyaoqi/automated-cherry-pick-of-#7547-upstream-release-3.3
Automated cherry pick of #7547: support diable usb kbd
2020-08-11 18:41:28 +08:00
Zexi Li
22231edba6 Merge pull request #7542 from ioito/automated-cherry-pick-of-#7541-upstream-release-3.3
Automated cherry pick of #7541: fix: separete enabled and status field
2020-08-11 18:39:18 +08:00
wanyaoqi
0742afb487 support diable usb kbd 2020-08-11 15:32:31 +08:00
Qu Xuan
3b036e6c30 fix: separete enabled and status field 2020-08-11 14:54:31 +08:00
Zexi Li
227fa57883 Merge pull request #7536 from wanyaoqi/automated-cherry-pick-of-#7530-upstream-release-3.3
Automated cherry pick of #7530: fix mount xfs
2020-08-11 11:16:20 +08:00
wanyaoqi
5439457bb4 fix usage get storage capbility (#7528) 2020-08-10 20:07:57 +08:00
wanyaoqi
57cd48354f fix mount xfs 2020-08-10 20:03:24 +08:00
屈轩
3c63af8de0 fix: optimized huawei security group get and create operation (#7521)
Co-authored-by: Qu Xuan <quxuan@yunionyun.com>
2020-08-10 15:37:44 +08:00
wanyaoqi
52488eeb50 set disk status on disk detached (#7518) 2020-08-10 12:05:45 +08:00
Zexi Li
9114556da3 Merge pull request #7516 from zhaoxiangchun/automated-cherry-pick-of-#7512-upstream-release-3.3
Automated cherry pick of #7512: nodealert bugfix:
2020-08-10 11:14:22 +08:00
zhaoxiangchun
abe44154ba nodealert bugfix:
1.重名判断:后端通过resType, nodeName, metric 限制前端可以创建相同metric的报警记录
2020-08-10 10:33:41 +08:00
Zexi Li
89de86a243 Merge pull request #7509 from ioito/automated-cherry-pick-of-#7508-upstream-release-3.3
Automated cherry pick of #7508: fix: avoid nil pointer
2020-08-10 10:24:53 +08:00
tb365
6cdbae22a4 add image upload& s3 upload api (#7515)
Co-authored-by: TangBin <tangbin@yunion.cn>
2020-08-10 10:21:44 +08:00
Qu Xuan
6f5be444c3 fix: avoid nil pointer 2020-08-07 11:16:00 +08:00
Zexi Li
13d165e3c1 Merge pull request #7504 from ioito/hotfix/qx-auto-create-project-fix
fix: backport fix
2020-08-07 11:06:57 +08:00
Zexi Li
d3d977a359 Merge pull request #7499 from ioito/automated-cherry-pick-of-#7498-upstream-release-3.3
Automated cherry pick of #7498: fix: 隐藏auzre经典类型存储
2020-08-07 11:06:07 +08:00
Zexi Li
0f37875b40 Merge pull request #7502 from ioito/automated-cherry-pick-of-#7501-upstream-release-3.3
Automated cherry pick of #7501: fix: 提高zstack认证兼容性
2020-08-07 11:05:14 +08:00
Qu Xuan
bb1752fb7b fix: backport fix 2020-08-06 20:48:49 +08:00
Qu Xuan
b152aa3337 fix: 提高zstack认证兼容性 2020-08-06 19:25:01 +08:00
Qu Xuan
bb01236942 fix: 隐藏auzre经典类型存储 2020-08-06 18:01:11 +08:00
屈轩
7a81820cd3 fix: 增加openstack兼容性 (#7493)
Co-authored-by: Qu Xuan <quxuan@yunionyun.com>
2020-08-06 11:56:18 +08:00
Zexi Li
525a18dde2 Merge pull request #7485 from wanyaoqi/automated-cherry-pick-of-#7484-upstream-release-3.3
Automated cherry pick of #7484: fix host info get sshkey
2020-08-04 13:51:17 +08:00
wanyaoqi
39bcc36c2d fix host info get sshkey 2020-08-04 10:36:40 +08:00
Zexi Li
138088027e Merge pull request #7481 from swordqiu/automated-cherry-pick-of-#7479-upstream-release-3.3
Automated cherry pick of #7479: fix: typo running_geusts => running_guests
2020-08-03 16:58:40 +08:00
Zexi Li
a023cf56e4 Merge pull request #7475 from ioito/automated-cherry-pick-of-#7474-upstream-release-3.3
Automated cherry pick of #7474: fix: typo
2020-08-03 16:57:44 +08:00
Zexi Li
a17e90ed3b Merge pull request #7478 from swordqiu/automated-cherry-pick-of-#7477-upstream-release-3.3
Automated cherry pick of #7477: fix: filter public network count by zone and region
2020-08-03 16:56:34 +08:00
Qiu Jian
2153a79dcb fix: typo running_geusts => running_guests 2020-08-03 16:33:23 +08:00
Qiu Jian
780cf826c7 fix: filter public network count by zone and region 2020-08-03 15:21:16 +08:00
Qu Xuan
62d2a732e2 fix: typo 2020-08-03 10:56:56 +08:00
Zexi Li
f6409e8511 Merge pull request #7472 from swordqiu/automated-cherry-pick-of-#7470-upstream-release-3.3
Automated cherry pick of #7470: fix: ignore bucket-set-acl not implemented error
2020-08-03 09:25:04 +08:00
Qiu Jian
4cbe29d0c5 fix: ignore bucket-set-acl not implemented error 2020-08-03 02:25:20 +08:00
Zexi Li
221fb3f527 Merge pull request #7469 from zexi/hotfix/update-apis
update apis generate model
2020-08-02 11:15:25 +08:00
Zexi Li
042cd597f6 update apis generate model 2020-08-02 11:13:29 +08:00
Zexi Li
aae065f06f Merge pull request #7468 from zexi/automated-cherry-pick-of-#7455-upstream-release-3.3
Automated cherry pick of #7455: fix: avoid generated codes having duplicate PerformSetScope methods
2020-08-02 10:53:12 +08:00
Qiu Jian
d834f3331e fix: avoid generated codes having duplicate PerformSetScope methods 2020-08-02 10:50:43 +08:00
Zexi Li
703f59760e Merge pull request #7448 from tb365/automated-cherry-pick-of-#7447-upstream-release-3.3
Automated cherry pick of #7447: aws elb listener&rule name too long fix
2020-08-02 10:07:56 +08:00
Zexi Li
5a1935bd54 Merge pull request #7454 from rainzm/automated-cherry-pick-of-#7453-upstream-release-3.3
Automated cherry pick of #7453: opt(scheduler): better sort for hosts when selectHost
2020-08-02 10:04:50 +08:00
屈轩
6e64fc4caa fix: avoid host globalid change (#7466)
Co-authored-by: Qu Xuan <quxuan@yunionyun.com>
2020-08-02 03:03:03 +08:00
wanyaoqi
8172a551bb fix reauth condition on influxdb not found (#7457) 2020-08-01 21:27:04 +08:00
wanyaoqi
381a2796ba fix cache non lvm disks (#7460) 2020-08-01 21:16:04 +08:00
rainzm
49b0a01b08 opt(scheduler): better sort for hosts when selectHost 2020-08-01 17:35:49 +08:00
Jian Qiu
88497da742 fix: elasticcache_account_reset_password_task.go cherry pick build fail (#7452)
Co-authored-by: Qiu Jian <qiujian@yunionyun.com>
2020-08-01 16:44:33 +08:00
tangbin
38e02db07f aws elb listener&rule name too long fix 2020-08-01 11:12:39 +08:00
Zexi Li
fbda89ce2a Merge pull request #7419 from rainzm/automated-cherry-pick-of-#7416-upstream-release-3.3
Automated cherry pick of #7416: fix(region): Don't allow address conflicts under vpc
2020-08-01 11:05:54 +08:00
Zexi Li
c11ee3ed56 Merge pull request #7437 from tb365/automated-cherry-pick-of-#7435-upstream-release-3.3
Automated cherry pick of #7435: loadblancer listener modify name fix
2020-08-01 10:58:00 +08:00
rainzm
18f5f9cb8c fix(region): Don't allow address conflicts under vpc
Except for default vpc, vpc and wire have a one-to-one correspondence.
So prohibiting the address conflict of wire does not avoid
the address conflict of default vpc.
2020-08-01 10:51:52 +08:00
tangbin
bb500edc81 fix redis reset account password action log 2020-08-01 10:51:21 +08:00
tangbin
d9488f552e loadblancer listener modify name fix 2020-08-01 10:50:24 +08:00
Zexi Li
b39e4e37e3 Merge pull request #7440 from swordqiu/automated-cherry-pick-of-#7438-upstream-release-3.3
Automated cherry pick of #7438: fix: sync share mode between vpc and wire
2020-08-01 10:39:43 +08:00
Zexi Li
880f889d4a Merge pull request #7442 from wanyaoqi/automated-cherry-pick-of-#7441-upstream-release-3.3
Automated cherry pick of #7441: fix deploy admin auth key
2020-08-01 00:05:55 +08:00
wanyaoqi
7ad7774f80 fix deploy admin auth key 2020-07-31 23:23:06 +08:00
Zexi Li
e64f249453 baremetal: fix hpssactl split last LV size out of limit (#7427) 2020-07-31 22:49:03 +08:00
Qiu Jian
9dfed28459 fix: sync share mode between vpc and wire 2020-07-31 22:31:06 +08:00
Zexi Li
dd7967dd65 Merge pull request #7434 from zexi/automated-cherry-pick-of-#7433-upstream-release-3.3
Automated cherry pick of #7433: capability: public network count filter by default vpc
2020-07-31 20:42:35 +08:00
Zexi Li
80ae1b6cde capability: public network count filter by default vpc 2020-07-31 20:29:57 +08:00
Zexi Li
b513216421 Merge pull request #7418 from ioito/automated-cherry-pick-of-#7417-upstream-release-3.3
Automated cherry pick of #7417: fix: avoid lost backend params
2020-07-31 18:07:39 +08:00
Zexi Li
a0b464b8d6 Merge pull request #7414 from ioito/automated-cherry-pick-of-#7413-upstream-release-3.3
Automated cherry pick of #7413: fix: openstack win image user data need encode
2020-07-31 18:06:41 +08:00
Zexi Li
d29b105efc Merge pull request #7406 from ioito/automated-cherry-pick-of-#7405-upstream-release-3.3
Automated cherry pick of #7405: fix: avoid account sync deadlock
2020-07-31 18:05:24 +08:00
Zexi Li
1cf42ccfcc Merge pull request #7409 from swordqiu/automated-cherry-pick-of-#7400-upstream-release-3.3
Automated cherry pick of #7400: fix: ignore general s3 set acl not implemented error
2020-07-31 18:04:12 +08:00
Zexi Li
353384f32a Merge pull request #7396 from yousong/automated-cherry-pick-of-#7395-upstream-release-3.3
Automated cherry pick of #7395: apis: compute: move struct defs
2020-07-31 18:03:26 +08:00
屈轩
92d8437c45 fix: 避免glance metadata-list project scope无权限 (#7403)
Co-authored-by: Qu Xuan <quxuan@yunionyun.com>
2020-07-31 18:01:39 +08:00
屈轩
65cd074ffa fix: 优化openstack项目认证 (#7398)
Co-authored-by: Qu Xuan <quxuan@yunionyun.com>
2020-07-31 18:00:09 +08:00
屈轩
5dc8296332 fix: 避免在仅调整虚拟机磁盘时opslog日志记录mem cpu异常 (#7393)
Co-authored-by: Qu Xuan <quxuan@yunionyun.com>
2020-07-31 17:56:57 +08:00
Qu Xuan
46fa77b29b fix: avoid lost backend params 2020-07-31 17:19:20 +08:00
Qu Xuan
c39de392c3 fix: openstack win image user data need encode 2020-07-31 16:54:47 +08:00
wanyaoqi
a2d562ccaa fix panic on storage failed get host (#7391) 2020-07-31 16:43:33 +08:00
Qiu Jian
7e47d7aeb4 fix: ignore general s3 set acl not implemented error 2020-07-31 16:38:51 +08:00
Qu Xuan
01f384cf80 fix: avoid account sync deadlock 2020-07-31 16:32:31 +08:00
Yousong Zhou
5833f1a905 lblisteners: remove unused acl_name field 2020-07-30 20:51:54 +08:00
Yousong Zhou
04abe448f1 lblisteners: list: show acl name 2020-07-30 20:51:54 +08:00
Yousong Zhou
ab71f5e6c6 lblisteners: list: show certificate name 2020-07-30 20:51:54 +08:00
Yousong Zhou
8a79c0f708 apis: compute: move struct defs 2020-07-30 20:51:53 +08:00
Zexi Li
c3bab46d23 Merge pull request #7388 from rainzm/automated-cherry-pick-of-#7387-upstream-release-3.3
Automated cherry pick of #7387: fix(region): zone from guesttemplate's preferzone maybe nil
2020-07-30 17:41:39 +08:00
rainzm
5ee9698218 fix(region): zone from guesttemplate's preferzone maybe nil 2020-07-30 16:12:03 +08:00
Zexi Li
925caf9111 Merge pull request #7352 from ioito/automated-cherry-pick-of-#7318-upstream-release-3.3
Automated cherry pick of #7318: fix: openstack多项目问题
2020-07-30 15:53:36 +08:00
Zexi Li
cc6f22d9d7 Merge pull request #7385 from ioito/automated-cherry-pick-of-#7384-upstream-release-3.3
Automated cherry pick of #7384: fix: avoid parse json err nil pointer
2020-07-30 15:15:33 +08:00
Qu Xuan
816b29267c fix: openstack多项目问题 2020-07-30 14:43:55 +08:00
Qu Xuan
f9b51a9f54 fix: avoid parse json err nil pointer 2020-07-30 11:31:57 +08:00
Zexi Li
14ddc69b40 Merge pull request #7379 from ioito/automated-cherry-pick-of-#7378-upstream-release-3.3
Automated cherry pick of #7378: fix: 添加阿里云rds备份恢复限制条件
2020-07-29 21:38:42 +08:00
Zexi Li
d1a2fe39a7 Merge pull request #7377 from swordqiu/automated-cherry-pick-of-#7375-upstream-release-3.3
Automated cherry pick of #7375: fix: change owner should check required domain list
2020-07-29 17:31:52 +08:00
Qu Xuan
ba953f20ce fix: 添加阿里云rds备份恢复限制条件 2020-07-29 16:55:41 +08:00
Qiu Jian
04b4ab3760 fix: change owner should check required domain list 2020-07-29 13:01:54 +08:00
Zexi Li
8fa3e77995 Merge pull request #7373 from ioito/automated-cherry-pick-of-#7358-upstream-release-3.3
Automated cherry pick of #7358: fix: 普通视图下,安全组仅统计可看到的vm count
2020-07-29 10:27:14 +08:00
Zexi Li
583d783ce6 Merge pull request #7372 from zexi/automated-cherry-pick-of-#7371-upstream-release-3.3
Automated cherry pick of #7371: region: schedtag list support resource_types
2020-07-28 20:57:33 +08:00
Zexi Li
fecb127100 Merge pull request #7360 from ioito/automated-cherry-pick-of-#7359-upstream-release-3.3
Automated cherry pick of #7359: fix: 修复vm绑定重复安全组
2020-07-28 20:55:54 +08:00
Qu Xuan
6b2cb20f4c fix: 普通视图下,安全组仅统计可看到的vm count 2020-07-28 20:53:10 +08:00
Zexi Li
632aef4fab Merge pull request #7369 from ioito/automated-cherry-pick-of-#7368-upstream-release-3.3
Automated cherry pick of #7368: fix: 同步sku与磁盘类型关系
2020-07-28 20:48:04 +08:00
Zexi Li
65562c25f5 region: schedtag list support resource_types 2020-07-28 20:46:27 +08:00
Qu Xuan
28a80ac52e fix: 同步sku与磁盘类型关系 2020-07-28 19:47:26 +08:00
Zexi Li
843c52c221 Merge pull request #7365 from zexi/automated-cherry-pick-of-#7364-upstream-release-3.3
Automated cherry pick of #7364: adjust schedule resource condition width
2020-07-28 18:50:23 +08:00
屈轩
bd6b45aaef fix: 避免创建rds备份时对rds进行一些操作 (#7355)
Co-authored-by: Qu Xuan <quxuan@yunionyun.com>
2020-07-28 18:47:58 +08:00
Zexi Li
7103f4e716 adjust schedule resource condition width 2020-07-28 18:36:58 +08:00
Qu Xuan
f03d021aa5 fix: 修复vm绑定重复安全组 2020-07-28 18:12:55 +08:00
Zexi Li
0b8baeef6a Merge pull request #7349 from wanyaoqi/automated-cherry-pick-of-#7348-upstream-release-3.3
Automated cherry pick of #7348: fix schedtag list output
2020-07-27 20:26:55 +08:00
wanyaoqi
2ac39e704a fix schedtag list output 2020-07-27 20:24:40 +08:00
Zexi Li
df63c8ddde Merge pull request #7339 from rainzm/automated-cherry-pick-of-#7338-upstream-release-3.3
Automated cherry pick of #7338: fix(region): Remove default secgroup for esxi guest
2020-07-27 19:49:19 +08:00
Zexi Li
e0b9cec7e8 Merge pull request #7344 from rainzm/automated-cherry-pick-of-#7343-upstream-release-3.3
Automated cherry pick of #7343: fix: modify list details for guesttemplate
2020-07-27 19:48:22 +08:00
Zexi Li
4d96c8fc75 Merge pull request #7347 from swordqiu/automated-cherry-pick-of-#7346-upstream-release-3.3
Automated cherry pick of #7346: fix: add default perform allow policy to sysadmin
2020-07-27 19:47:24 +08:00
Qiu Jian
3f09d00198 fix: add default perform allow policy to sysadmin 2020-07-27 19:11:17 +08:00
Zexi Li
738425170b Merge pull request #7337 from yousong/automated-cherry-pick-of-#7336-upstream-release-3.3
Automated cherry pick of #7336: guests: guests with vpc nics are available for eip association
2020-07-27 15:54:58 +08:00
Zexi Li
27a4696a6d Merge pull request #7323 from swordqiu/automated-cherry-pick-of-#7321-upstream-release-3.3
Automated cherry pick of #7321: fix: choose candidate list from the list returned from backend
2020-07-27 15:54:03 +08:00
Zexi Li
ce13c0cbe9 Merge pull request #7320 from ioito/automated-cherry-pick-of-#7319-upstream-release-3.3
Automated cherry pick of #7319: fix: 单独添加更新账单文件日志
2020-07-27 15:52:53 +08:00
Zexi Li
3617855bcb Merge pull request #7317 from zhaoxiangchun/automated-cherry-pick-of-#7316-upstream-release-3.3
Automated cherry pick of #7316: 修复统一报警bug
2020-07-27 15:51:55 +08:00
Zexi Li
0d66aaa734 Merge pull request #7326 from swordqiu/automated-cherry-pick-of-#7324-upstream-release-3.3
Automated cherry pick of #7324: fix: schedtag should be system resource
2020-07-27 15:50:04 +08:00
Zexi Li
b68c40e5a5 Merge pull request #7331 from swordqiu/automated-cherry-pick-of-#7330-upstream-release-3.3
Automated cherry pick of #7330: fix: do accessibility check when dissociate eip from resource
2020-07-27 15:22:23 +08:00
Zexi Li
c40ececb34 Merge pull request #7329 from tb365/automated-cherry-pick-of-#7327-upstream-release-3.3
Automated cherry pick of #7327: huawei fetch regions&projects fix
2020-07-27 15:22:00 +08:00
rainzm
a66ba3f391 Add metadata for GuestTempalte details 2020-07-27 15:17:55 +08:00
rainzm
02b30326fd Add network info when list scalingGroup details 2020-07-27 15:17:55 +08:00
rainzm
d06d2026f4 fix: modify list details for guesttemplate 2020-07-27 15:17:55 +08:00
Zexi Li
35ddf5da65 Merge pull request #7334 from swordqiu/automated-cherry-pick-of-#7332-upstream-release-3.3
Automated cherry pick of #7332: fix: cloud account delete may fail due to inconsistent status
2020-07-27 15:13:09 +08:00
rainzm
cd01258555 fix(region): Remove default secgroup for esxi guest
1. InitializeData remove all secgroup_id of esxi guest from database
2. Set input.SecgroupId as empty for guest whose GetMaxSecurityGroupCount
return 0
2020-07-27 14:53:45 +08:00
Yousong Zhou
2270704c4f guests: guests with vpc nics are available for eip association 2020-07-27 11:01:47 +08:00
屈轩
f2456d2364 fix: 避免status_code>=400并且resp为空时err为nil (#7265)
Co-authored-by: Qu Xuan <quxuan@yunionyun.com>
2020-07-27 04:42:52 +08:00
yunion-ci-robot
8d1d9ece01 Merge pull request #7312 from ioito/automated-cherry-pick-of-#7310-upstream-release-3.3
Automated cherry pick of #7310: fix: 支持多项目安全组规则过滤
2020-07-26 00:03:54 +08:00
Qiu Jian
f624ab1529 fix: cloud account delete may fail due to inconsistent status 2020-07-25 23:10:24 +08:00
Qiu Jian
ded8da0016 fix: do accessibility check when dissociate eip from resource 2020-07-24 22:54:41 +08:00
yunion-ci-robot
58ed07b4e3 Merge pull request #7304 from wanyaoqi/automated-cherry-pick-of-#7302-upstream-release-3.3
Automated cherry pick of #7302: fix clone clean pending usage
2020-07-24 22:52:43 +08:00
zhaoxiangchun
6193221764 修改报警消息模版:
1.模版中使用ftm.sprintf
  对float类型进行转换,避免消息中数值以十进制的指数次格式显示,提高可读性
2.增加text/tempalte,解决飞书等消息中消息内容被编码的问题
2020-07-24 22:41:11 +08:00
zhaoxiangchun
bb66e2d197 修复统一报警bug
1.对系统内置的规则的处理,可以进行正确判断推送消息
2.一些初始化,validate的判断逻辑的修改
2020-07-24 22:41:11 +08:00
tangbin
92fbc44b6d go fmt 2020-07-24 18:29:15 +08:00
tangbin
d93edbe427 go fmt 2020-07-24 18:29:14 +08:00
tangbin
a4d89b1f6c host upload template check 2020-07-24 18:29:14 +08:00
tangbin
5255df021e huawei fetch regions&projects fix 2020-07-24 18:29:14 +08:00
Qiu Jian
4d33d1a703 fix: schedtag should be system resource 2020-07-24 17:04:45 +08:00
Qiu Jian
c90c0944c1 fix: choose candidate list from the list returned from backend 2020-07-24 16:44:23 +08:00
Qu Xuan
e7fc9b94b0 fix: 单独添加更新账单文件日志 2020-07-24 14:31:36 +08:00
Zexi Li
7512e48236 Merge pull request #7292 from wanyaoqi/automated-cherry-pick-of-#7143-upstream-release-3.3
Automated cherry pick of #7143: - add precheck for perform action
2020-07-24 10:48:14 +08:00
Zexi Li
bb6e4b4610 Merge pull request #7315 from wanyaoqi/automated-cherry-pick-of-#7314-upstream-release-3.3
Automated cherry pick of #7314: rename vgname centos
2020-07-24 10:47:01 +08:00
wanyaoqi
7ef340fb68 rename vgname centos 2020-07-23 21:33:26 +08:00
Qu Xuan
fef5147ae4 fix: 支持多项目安全组规则过滤 2020-07-23 20:36:27 +08:00
Zexi Li
afed84a502 Merge pull request #7309 from swordqiu/automated-cherry-pick-of-#7303-upstream-release-3.3
Automated cherry pick of #7303: fix: domain resource domain share to system when non_default_domain_projects off
2020-07-23 20:34:08 +08:00
wanyaoqi
a329cd536b fix clone clean pending usage 2020-07-23 18:38:34 +08:00
wanyaoqi
32b36ee10e capabilites add available host count 2020-07-23 18:16:23 +08:00
Qiu Jian
671d202271 fix: domain resource domain share to system when non_default_domain_projects off 2020-07-23 17:57:59 +08:00
Zexi Li
7e629b3c80 Merge pull request #7295 from wanyaoqi/automated-cherry-pick-of-#7294-upstream-release-3.3
Automated cherry pick of #7294: fix snapshot clean pending usage
2020-07-23 13:48:03 +08:00
Zexi Li
3d3ff3f866 Merge pull request #7280 from rainzm/automated-cherry-pick-of-#7279-upstream-release-3.3
Automated cherry pick of #7279: feat(scheduler): Change the action for guests with backup and instanceGroup
2020-07-23 13:36:20 +08:00
wanyaoqi
2c27db42c2 fix snapshot clean pending usage 2020-07-23 11:35:39 +08:00
Zexi Li
18dd47c713 Merge pull request #7287 from tb365/automated-cherry-pick-of-#7286-upstream-release-3.3
Automated cherry pick of #7286: apigateway host imports data validate
2020-07-22 21:43:39 +08:00
wanyaoqi
ec933e4805 - add precheck for perform action
- auto switch to backup

- add sync cleand schedule cache

- add reconcile with backup

- add manual reconcile backup
2020-07-22 21:12:32 +08:00
tangbin
2ff5d2aaf4 format fix 2020-07-22 17:50:13 +08:00
tangbin
b5aceb67f9 fix empty else 2020-07-22 17:50:13 +08:00
tangbin
2794c84ac0 fix host import 2020-07-22 17:50:11 +08:00
tangbin
ce9646f9e9 fix huawei delete resource 2020-07-22 17:50:10 +08:00
tangbin
be8da39ce1 fix huawei elb disable healthcheck 2020-07-22 17:50:10 +08:00
tangbin
dacc8adce1 lb sync project fix 2020-07-22 17:50:10 +08:00
tangbin
b79c410b0e add more log 2020-07-22 17:50:09 +08:00
tangbin
b5754d2e3d apigateway host imports data validate 2020-07-22 17:50:09 +08:00
Zexi Li
8a6ee6c9ab Merge pull request #7277 from ioito/automated-cherry-pick-of-#7276-upstream-release-3.3
Automated cherry pick of #7276: fix: 避免未能导出共享安全组规则
2020-07-22 13:55:41 +08:00
Zexi Li
309c1ca3f1 Merge pull request #7274 from swordqiu/automated-cherry-pick-of-#7273-upstream-release-3.3
Automated cherry pick of #7273: fix: image upload not clean pending usage
2020-07-22 13:54:37 +08:00
Zexi Li
f3bc3ca51d Merge pull request #7282 from rainzm/automated-cherry-pick-of-#7281-upstream-release-3.3
Automated cherry pick of #7281: fix(esxi): Select correct unitNumber for ide control when creating disk
2020-07-22 13:52:22 +08:00
Rain Zheng
7c82002903 fix(esxi): Select correct unitNumber for ide control when creating disk 2020-07-21 20:48:39 +08:00
rainzm
2a0c16c6f3 feat(scheduler): Change the action for guests with backup and instanceGroup
1. 对于主机组的打散功能,放在调度的最后单独处理。
2. 主备机的调度,通过在主机和备机之间设置一个粒度为1的主机组来实现。
3. 虚拟机的调度默认打散,在打散的基础上,选择容量大的宿主机。
3. 主备机中,主机和备机的默认打散流程分散开,互不影响。
2020-07-21 20:34:36 +08:00
Qu Xuan
1c4e9e00a5 fix: 避免未能导出共享安全组规则 2020-07-21 17:14:18 +08:00
yunion-ci-robot
3599904eee Merge pull request #7271 from zexi/automated-cherry-pick-of-#7270-upstream-release-3.3
Automated cherry pick of #7270: baremetal: set zone when enable netif
2020-07-21 11:48:24 +08:00
Qiu Jian
ba983df32b fix: image upload not clean pending usage 2020-07-21 01:43:04 +08:00
yunion-ci-robot
194105f4d3 Merge pull request #7268 from tb365/automated-cherry-pick-of-#7267-upstream-release-3.3
Automated cherry pick of #7267: fix GetOrCreateVpcForClassicNetwork
2020-07-20 20:49:28 +08:00
Zexi Li
ea374ac0c0 Merge pull request #7263 from tb365/automated-cherry-pick-of-#7237-upstream-release-3.3
Automated cherry pick of #7237: huawei eip delete fix
2020-07-20 20:47:39 +08:00
Zexi Li
df4d88e195 baremetal: set zone when enable netif 2020-07-20 20:45:06 +08:00
tangbin
f9c4221125 fix GetOrCreateVpcForClassicNetwork 2020-07-20 18:28:48 +08:00
Zexi Li
f246c47a33 Merge pull request #7258 from yousong/bugfix/yousong-lbagent-create-influxdb
[3.3] region: lbagents: skip tls check for default influxdb endpoint url
2020-07-20 12:21:51 +08:00
tangbin
fdcaa1c8e7 huawei eip delete fix 2020-07-20 10:52:31 +08:00
Yousong Zhou
7f7aef031a region: lbagents: skip tls check for default influxdb endpoint url 2020-07-20 09:01:50 +08:00
Zexi Li
1451a75646 Merge pull request #7239 from rainzm/automated-cherry-pick-of-#7238-upstream-release-3.3
Automated cherry pick of #7238: fix: default vpc must be shared globally
2020-07-20 02:09:39 +08:00
Zexi Li
5c57493f5b Merge pull request #7240 from ioito/automated-cherry-pick-of-#7225-upstream-release-3.3
Automated cherry pick of #7225: fix: rds备份恢复优化
2020-07-20 02:07:41 +08:00
Zexi Li
af2bf4e8cd Merge pull request #7229 from wanyaoqi/automated-cherry-pick-of-#7228-upstream-release-3.3
Automated cherry pick of #7228: fix server sync status
2020-07-20 02:06:28 +08:00
Zexi Li
42fbf12d66 Merge pull request #7235 from ioito/automated-cherry-pick-of-#7234-upstream-release-3.3
Automated cherry pick of #7234: fix: globalvpc跟随云账号共享
2020-07-20 02:05:09 +08:00
Zexi Li
1ec53dbf7f Merge pull request #7257 from zhaoxiangchun/automated-cherry-pick-of-#7256-upstream-release-3.3
Automated cherry pick of #7256: 修复监控报警规则删除的问题
2020-07-20 02:03:50 +08:00
Zexi Li
37c2e004fb Merge pull request #7233 from tb365/automated-cherry-pick-of-#7231-upstream-release-3.3
Automated cherry pick of #7231: acl delete condition fix
2020-07-20 02:02:36 +08:00
zhaoxiangchun
c65fc0f1dc 修复监控报警规则删除的问题 2020-07-19 21:29:13 +08:00
Zexi Li
c371e04aaf Merge pull request #7249 from wanyaoqi/automated-cherry-pick-of-#7248-upstream-release-3.3
Automated cherry pick of #7248: fix error output
2020-07-19 20:53:47 +08:00
Zexi Li
9c61ce86cc Merge pull request #7255 from zexi/automated-cherry-pick-of-#7254-upstream-release-3.3
Automated cherry pick of #7254: scheduler: fix storage filter duplicate error message
2020-07-19 20:52:53 +08:00
Zexi Li
d6b1fa02d8 scheduler: fix storage filter duplicate error message 2020-07-19 20:26:56 +08:00
Zexi Li
e3cd4be117 Merge pull request #7253 from swordqiu/automated-cherry-pick-of-#7251-upstream-release-3.3
Automated cherry pick of #7251: fix: quota usage not updated after disk resizing
2020-07-19 20:25:12 +08:00
Qiu Jian
508f30901a fix: quota usage not updated after disk resizing 2020-07-19 13:25:04 +08:00
wanyaoqi
18bae18498 fix error output 2020-07-19 12:35:04 +08:00
Qu Xuan
ecb7249a1d fix: rds备份恢复优化 2020-07-18 20:47:47 +08:00
rainzm
fa67bd8312 fix: default vpc must be shared globally
1. For default vpc, prohibit private operation.
2. For default vpc, prohibit public operation without scope 'system'.
2020-07-18 19:42:19 +08:00
Qu Xuan
f8471832e9 fix: globalvpc跟随云账号共享 2020-07-17 20:46:32 +08:00
tangbin
3e5eceeefa acl delete condition fix 2020-07-17 20:44:52 +08:00
wanyaoqi
0e617ec137 fix server sync status 2020-07-17 20:25:16 +08:00
Zexi Li
9b1ea9f303 Merge pull request #7226 from ioito/automated-cherry-pick-of-#7224-upstream-release-3.3
Automated cherry pick of #7224: fix: 过滤可用eip
2020-07-17 20:25:09 +08:00
Zexi Li
94555e348c Merge pull request #7222 from ioito/automated-cherry-pick-of-#7221-upstream-release-3.3
Automated cherry pick of #7221: fix: 避免乌兰察布区域拉取资源异常
2020-07-17 20:24:01 +08:00
Qu Xuan
23e17fe0a1 fix: 过滤可用eip 2020-07-17 20:16:27 +08:00
Qu Xuan
a443975f7e fix: 避免乌兰察布区域拉取资源异常 2020-07-17 18:52:52 +08:00
Zexi Li
5cd0873ee8 Merge pull request #7217 from rainzm/automated-cherry-pick-of-#7216-upstream-release-3.3
Automated cherry pick of #7216: fix: prefetch image error when create guest with vmware template
2020-07-17 10:16:36 +08:00
Zexi Li
7e796affb3 Merge pull request #7214 from tb365/automated-cherry-pick-of-#7213-upstream-release-3.3
Automated cherry pick of #7213: sync classic redis fix
2020-07-17 10:15:48 +08:00
Zexi Li
4b2cb45b0c Merge pull request #7204 from yousong/automated-cherry-pick-of-#7202-upstream-release-3.3
Automated cherry pick of #7202: mcclient: options: loadbalanceragents: yum as the default deploy method
2020-07-17 10:15:10 +08:00
Zexi Li
dde94aa754 Merge pull request #7199 from yousong/automated-cherry-pick-of-#7198-upstream-release-3.3
Automated cherry pick of #7198: ansibleserver: register metadata manager
2020-07-17 10:11:56 +08:00
Zexi Li
771d8b42aa Merge pull request #7196 from ioito/automated-cherry-pick-of-#7195-upstream-release-3.3
Automated cherry pick of #7195: fix: sec rule export missing fields
2020-07-17 10:10:23 +08:00
Zexi Li
544b62c683 Merge pull request #7193 from wanyaoqi/automated-cherry-pick-of-#7192-upstream-release-3.3
Automated cherry pick of #7192: add params auto_migrate_on_host_down
2020-07-17 10:09:09 +08:00
Zexi Li
1c2c0c75f4 Merge pull request #7211 from ioito/automated-cherry-pick-of-#7210-upstream-release-3.3
Automated cherry pick of #7210: fix: not work for network-list --zones
2020-07-17 10:08:15 +08:00
rainzm
4ef5267a85 fix: prefetch image error when create guest with vmware template
1. Only need the corresponding vmware template in the vcenter where the host is
located.
2. Chose storagecache which cacheimage is ready before deploying.
2020-07-16 21:37:14 +08:00
tangbin
30aa75e047 sync classic redis fix 2020-07-16 20:29:20 +08:00
yunion-ci-robot
1b29a59d8f Merge pull request #7203 from zexi/automated-cherry-pick-of-#7201-upstream-release-3.3
Automated cherry pick of #7201: webconsole: fix old session make new session closed
2020-07-16 20:22:18 +08:00
Qu Xuan
d6b83fbbf8 fix: not work for network-list --zones 2020-07-16 19:06:04 +08:00
Yousong Zhou
f30b191d05 region: lbagents: turn off guest src check 2020-07-16 18:50:05 +08:00
Yousong Zhou
4a0d019b6e region: loadbalanceragents: yum as the default method 2020-07-16 18:50:05 +08:00
Yousong Zhou
5218f8aab3 mcclient: options: loadbalanceragents: yum as the default deploy method 2020-07-16 18:50:05 +08:00
Zexi Li
37ee6f8446 webconsole: fix old session make new session closed 2020-07-16 18:49:54 +08:00
Yousong Zhou
e5dd8efd7a build: ansibleserver: use native alpine, include openssh 2020-07-16 18:09:52 +08:00
Yousong Zhou
916943a7c2 ansibleserver: register metadata manager
To quash the following error in log

  [E 200716 15:20:40 db.(*SMetadataResourceBaseModelManager).FetchCustomizeColumns(metadataresource.go:136)] FetchQueryObjectsByIds metadata fail Error 1146: Table 'yunionansible.metadata_tbl' doesn't exist
2020-07-16 18:09:52 +08:00
Qu Xuan
cee24b2a7d fix: sec rule export missing fields 2020-07-16 17:14:17 +08:00
wanyaoqi
b806e536f1 add params auto_migrate_on_host_down 2020-07-16 15:03:05 +08:00
Zexi Li
0bfba15dfc Merge pull request #7172 from ioito/automated-cherry-pick-of-#7171-upstream-release-3.3
Automated cherry pick of #7171: fix: 修复cloudid get权限问题
2020-07-16 11:19:23 +08:00
Zexi Li
a933d5d7a8 Merge pull request #7175 from ioito/automated-cherry-pick-of-#7174-upstream-release-3.3
Automated cherry pick of #7174: fix: 添加secgroup rule过滤参数
2020-07-16 11:18:49 +08:00
Zexi Li
c09174dd39 Merge pull request #7187 from ioito/automated-cherry-pick-of-#7186-upstream-release-3.3
Automated cherry pick of #7186: fix: clouduser's cloudgroups info
2020-07-16 11:18:09 +08:00
Zexi Li
1a36e3a512 Merge pull request #7189 from ioito/automated-cherry-pick-of-#7188-upstream-release-3.3
Automated cherry pick of #7188: fix: check azure image format when rebuild root
2020-07-16 11:09:31 +08:00
Zexi Li
cac1db5391 Merge pull request #7178 from ioito/automated-cherry-pick-of-#7177-upstream-release-3.3
Automated cherry pick of #7177: fix: 避免华为云安全组规则删除失败
2020-07-16 10:15:30 +08:00
Qu Xuan
1b5b8081f1 fix: check azure image format when rebuild root 2020-07-15 18:48:00 +08:00
Zexi Li
52e02d85b9 Merge pull request #7184 from wanyaoqi/automated-cherry-pick-of-#7151-upstream-release-3.3
Automated cherry pick of #7151: disable procutils print error info
2020-07-15 17:43:06 +08:00
Zexi Li
14f10307c1 Merge pull request #7182 from wanyaoqi/automated-cherry-pick-of-#7181-upstream-release-3.3
Automated cherry pick of #7181: misc ha guest fix
2020-07-15 17:42:44 +08:00
Qu Xuan
64599b4819 fix: 避免华为云安全组规则删除失败 2020-07-15 17:13:55 +08:00
Qu Xuan
fb229f6c79 fix: clouduser's cloudgroups info 2020-07-15 17:09:23 +08:00
wanyaoqi
65408519ae misc ha guest fix 2020-07-15 17:06:02 +08:00
wanyaoqi
4831aee2dc disable procutils print error info 2020-07-15 17:02:11 +08:00
Qu Xuan
a5fc7c807c fix: 添加secgroup rule过滤参数 2020-07-15 14:31:43 +08:00
Qu Xuan
09f2b2af26 fix: 修复cloudid get权限问题 2020-07-15 11:08:17 +08:00
Zexi Li
2b923eb5b7 Merge pull request #7169 from wanyaoqi/automated-cherry-pick-of-#7168-upstream-release-3.3
Automated cherry pick of #7168: fix list guests on host
2020-07-15 10:45:59 +08:00
Zexi Li
ebe81b9c51 Merge pull request #7167 from ioito/automated-cherry-pick-of-#7166-upstream-release-3.3
Automated cherry pick of #7166: fix: 修复cloudid用户列表权限问题
2020-07-15 10:35:58 +08:00
Zexi Li
b31f35ba26 Merge pull request #7159 from yousong/automated-cherry-pick-of-#7158-upstream-release-3.3
Automated cherry pick of #7158: iproute2: address: make Exact idempotent
2020-07-15 10:34:36 +08:00
Zexi Li
f9c6a23280 Merge pull request #7165 from tb365/automated-cherry-pick-of-#7163-upstream-release-3.3
Automated cherry pick of #7163: cloudprovider usable filter with zone
2020-07-15 10:33:59 +08:00
wanyaoqi
f09eb6690d fix list guests on host 2020-07-14 22:34:48 +08:00
Qu Xuan
c003f78f62 fix: azure 支持权限 2020-07-14 21:24:24 +08:00
Qu Xuan
26434683c4 fix: 修复cloudid用户列表权限问题 2020-07-14 21:10:59 +08:00
tangbin
26757cb8d8 cloudprovider usable filter with zone 2020-07-14 19:55:51 +08:00
Zexi Li
c90420b61f Merge pull request #7156 from ioito/automated-cherry-pick-of-#7155-upstream-release-3.3
Automated cherry pick of #7155: fix: 优化webconsole代码&bugfix
2020-07-14 17:53:04 +08:00
Yousong Zhou
4b6d385e1a iproute2: address: make Exact idempotent
Idempotence against address not available for Exact is not a bad idea if
we look at the name of that func

This should accomodate the race condition where keepalived will remove
vips should the primary address used for vrrp comms is removed, causing
later addr del to fail with "cannot assign requested address"
2020-07-14 16:41:48 +08:00
Qu Xuan
ea3097240e fix: 优化webconsole代码&bugfix 2020-07-14 15:08:58 +08:00
Zexi Li
1881789981 Merge pull request #7153 from zexi/automated-cherry-pick-of-#7152-upstream-release-3.3
Automated cherry pick of #7152: climc: refactor k8s resource
2020-07-14 12:19:35 +08:00
Zexi Li
a6db3d353c climc: refactor k8s resource 2020-07-14 11:45:39 +08:00
Zexi Li
4882ead845 Merge pull request #7146 from rainzm/automated-cherry-pick-of-#7145-upstream-release-3.3
Automated cherry pick of #7145: fix guest template health check
2020-07-14 11:35:43 +08:00
Zexi Li
8a8d0e1cb3 Merge pull request #7148 from rainzm/automated-cherry-pick-of-#7147-upstream-release-3.3
Automated cherry pick of #7147: fix: mo.VirtualMachine's Config maybe nil
2020-07-14 11:34:43 +08:00
Zexi Li
bb2e014514 Merge pull request #7144 from zexi/hotfix/remove-informer-informer-3.3
remove informer code for release/3.3
2020-07-14 11:34:08 +08:00
rainzm
0420266b7d fix: mo.VirtualMachine's Config maybe nil 2020-07-13 23:09:57 +08:00
rainzm
550883197f fix guest template health check 2020-07-13 22:56:18 +08:00
Zexi Li
a365a0f459 remove informer code for release/3.3 2020-07-13 21:40:02 +08:00
Zexi Li
5d82212284 Merge pull request #7137 from tb365/automated-cherry-pick-of-#7135-upstream-release-3.3
Automated cherry pick of #7135: user batch register bugfix
2020-07-13 21:28:44 +08:00
Zexi Li
99caf7b142 Merge pull request #7141 from ioito/automated-cherry-pick-of-#7140-upstream-release-3.3
Automated cherry pick of #7140: fix: 修复阿里云同步安全组规则异常问题
2020-07-13 21:24:31 +08:00
Qu Xuan
2f42e9e5f4 fix: 修复阿里云同步安全组规则异常问题 2020-07-13 20:45:41 +08:00
tangbin
b52eb8491c user batch register bugfix 2020-07-13 14:58:26 +08:00
Zexi Li
32638ac3c0 Merge pull request #7131 from wanyaoqi/automated-cherry-pick-of-#7130-upstream-release-3.3
Automated cherry pick of #7130: vendor update: update jsonutils
2020-07-10 20:18:12 +08:00
Zexi Li
2bc5db8d20 Merge pull request #7126 from wanyaoqi/automated-cherry-pick-of-#7125-upstream-release-3.3
Automated cherry pick of #7125: - fix local storage init local man
2020-07-10 20:15:39 +08:00
wanyaoqi
d335c570c6 vendor update: update jsonutils 2020-07-10 16:18:54 +08:00
wanyaoqi
fe472cbf49 - fix local storage init local man
- fix rbd set storage info
2020-07-10 14:48:58 +08:00
Zexi Li
c17436cdb0 Merge pull request #7124 from swordqiu/automated-cherry-pick-of-#7123-upstream-release-3.3
Automated cherry pick of #7123: hotfix: vpc change owners with wire
2020-07-10 10:27:44 +08:00
Zexi Li
a2d7854fb7 Merge pull request #7122 from wanyaoqi/automated-cherry-pick-of-#7121-upstream-release-3.3
Automated cherry pick of #7121: misc fix
2020-07-10 10:27:15 +08:00
Zexi Li
39776f339a Merge pull request #7120 from ioito/automated-cherry-pick-of-#7119-upstream-release-3.3
Automated cherry pick of #7119: fix: 避免google clouduser同步权限异常
2020-07-10 10:26:51 +08:00
Qiu Jian
c97e2ab1c2 hotfix: vpc change owners with wire 2020-07-10 01:50:28 +08:00
wanyaoqi
5070775cd3 misc fix 2020-07-09 22:22:12 +08:00
Qu Xuan
7056fa01b4 fix: 避免google clouduser同步权限异常 2020-07-09 21:37:33 +08:00
Zexi Li
3f391649c6 Merge pull request #7117 from ioito/automated-cherry-pick-of-#7116-upstream-release-3.3
Automated cherry pick of #7116: fix: 修复vpc同步异常问题
2020-07-09 21:23:11 +08:00
Zexi Li
f73e11b0bd Merge pull request #7107 from wanyaoqi/automated-cherry-pick-of-#7106-upstream-release-3.3
Automated cherry pick of #7106: fix set storage info bind mount
2020-07-09 21:23:00 +08:00
Zexi Li
99cf724d2c Merge pull request #7114 from ioito/automated-cherry-pick-of-#7113-upstream-release-3.3
Automated cherry pick of #7113: fix: 避免越界访问
2020-07-09 21:21:17 +08:00
Qu Xuan
ef6d0c2adc fix: 修复vpc同步异常问题 2020-07-09 21:05:09 +08:00
Qu Xuan
09ccf107cb fix: 避免越界访问 2020-07-09 20:24:41 +08:00
yunion-ci-robot
cea59e8794 Merge pull request #7105 from tb365/automated-cherry-pick-of-#7096-upstream-release-3.3
Automated cherry pick of #7096: update vendor
2020-07-09 16:13:57 +08:00
wanyaoqi
18a023f2fb fix set storage info bind mount 2020-07-09 14:54:53 +08:00
Zexi Li
4c1d9e5e0f Merge pull request #7103 from swordqiu/automated-cherry-pick-of-#7102-upstream-release-3.3
Automated cherry pick of #7102: fix: opslog show the owners operation logs only
2020-07-09 14:18:55 +08:00
Zexi Li
db43b87568 Merge pull request #7101 from swordqiu/automated-cherry-pick-of-#7100-upstream-release-3.3
Automated cherry pick of #7100: fix: remove default allow policy for storages
2020-07-09 14:06:59 +08:00
Zexi Li
25d34f34b0 Merge pull request #7099 from ioito/automated-cherry-pick-of-#7098-upstream-release-3.3
Automated cherry pick of #7098: fix: cloudid 权限修复
2020-07-09 14:03:37 +08:00
tangbin
13f44debcd update vendor 2020-07-09 13:42:03 +08:00
Qiu Jian
a186f25871 fix: opslog show the owners operation logs only 2020-07-09 11:26:13 +08:00
Qiu Jian
8f7223b1d6 fix: remove default allow policy for storages 2020-07-09 11:15:19 +08:00
Qu Xuan
05c730acea fix: cloudid 权限修复 2020-07-09 10:46:50 +08:00
Zexi Li
b921d993ab Merge pull request #7097 from ioito/automated-cherry-pick-of-#7083-upstream-release-3.3
Automated cherry pick of #7083: fix: cloudid 异常修复
2020-07-08 21:26:09 +08:00
Zexi Li
434e0d8be2 Merge pull request #7094 from ioito/automated-cherry-pick-of-#7093-upstream-release-3.3
Automated cherry pick of #7093: fix: 修复资源组云上同步异常问题
2020-07-08 21:24:25 +08:00
Qu Xuan
b4ed259633 fix: cloudid 异常修复 2020-07-08 21:01:19 +08:00
Qu Xuan
89cb75bfeb fix: 修复资源组云上同步异常问题 2020-07-08 16:25:41 +08:00
Zexi Li
1ca0859d51 Merge pull request #7092 from ioito/automated-cherry-pick-of-#7091-upstream-release-3.3
Automated cherry pick of #7091: fix: 修复qcloud同步权限组异常问题
2020-07-08 14:10:42 +08:00
Zexi Li
f62bd8968e Merge pull request #7086 from ioito/automated-cherry-pick-of-#7085-upstream-release-3.3
Automated cherry pick of #7085: fix: 避免请求中国区iam异常
2020-07-08 14:10:19 +08:00
Zexi Li
136f2c547d Merge pull request #7080 from ioito/automated-cherry-pick-of-#7079-upstream-release-3.3
Automated cherry pick of #7079: fix: 修复腾讯云操作日志时间异常问题
2020-07-08 14:09:32 +08:00
Zexi Li
1caf8b6c0b Merge pull request #7089 from ioito/automated-cherry-pick-of-#7088-upstream-release-3.3
Automated cherry pick of #7088: fix: 修复azure 项目同步问题
2020-07-08 01:38:02 +08:00
Zexi Li
8f6b72bb82 Merge pull request #7084 from swordqiu/automated-cherry-pick-of-#7069-upstream-release-3.3
Automated cherry pick of #7069: fix: perform private on vpc will private all wires if no networks in wires
2020-07-07 22:37:45 +08:00
Qu Xuan
21178638f0 fix: 修复qcloud同步权限组异常问题 2020-07-07 19:48:53 +08:00
Qu Xuan
e8ff39a011 fix: 修复azure 项目同步问题 2020-07-07 18:44:09 +08:00
Qu Xuan
5f9b6622f0 fix: 避免请求中国区iam异常 2020-07-07 16:56:45 +08:00
Qiu Jian
2286ef19b4 fix: perform private on vpc will private all wires if no networks in wires 2020-07-07 16:14:28 +08:00
Qu Xuan
8a1d2d1eaf fix: 修复腾讯云操作日志时间异常问题 2020-07-07 14:58:49 +08:00
Zexi Li
adc50ec864 Merge pull request #7055 from ioito/automated-cherry-pick-of-#7054-upstream-release-3.3
Automated cherry pick of #7054: fix: 避免cloudprovider同步缺失
2020-07-07 14:49:03 +08:00
Zexi Li
4963d750fb Merge pull request #7060 from ioito/automated-cherry-pick-of-#7059-upstream-release-3.3
Automated cherry pick of #7059: fix: cloud poilcy count
2020-07-07 14:48:17 +08:00
Zexi Li
8bc891590d Merge pull request #7072 from ioito/automated-cherry-pick-of-#7066-upstream-release-3.3
Automated cherry pick of #7066: fix: json request 支持自定义匹配err
2020-07-07 14:46:44 +08:00
Zexi Li
efbf033c2d Merge pull request #7052 from ioito/automated-cherry-pick-of-#7050-upstream-release-3.3
Automated cherry pick of #7050: fix: google rds regional and zonal
2020-07-07 14:45:44 +08:00
Zexi Li
4fe7006920 Merge pull request #7078 from ioito/automated-cherry-pick-of-#7077-upstream-release-3.3
Automated cherry pick of #7077: fix: 修复elastic cache sku zone_id异常问题
2020-07-07 14:44:12 +08:00
Zexi Li
5e0d66d5df Merge pull request #7075 from ioito/automated-cherry-pick-of-#7074-upstream-release-3.3
Automated cherry pick of #7074: fix: 分开统计安全组关联虚拟机数量
2020-07-07 14:43:35 +08:00
Qu Xuan
76906efea2 fix: 修复elastic cache sku zone_id异常问题 2020-07-07 12:11:58 +08:00
Qu Xuan
a997cf4982 fix: 分开统计安全组关联虚拟机数量 2020-07-07 11:49:11 +08:00
Qu Xuan
6ac6768e36 fix: json request 支持自定义匹配err 2020-07-07 11:16:58 +08:00
Zexi Li
acdc1dafd3 Merge pull request #7068 from swordqiu/automated-cherry-pick-of-#7067-upstream-release-3.3
Automated cherry pick of #7067: fix: remove default host list policy
2020-07-07 11:14:44 +08:00
Zexi Li
b60c97822d Merge pull request #7057 from yousong/automated-cherry-pick-of-#7056-upstream-release-3.3
Automated cherry pick of #7056: vpcagent: ClaimVpcGuestDnsRecords: guard against pending_deleted guests
2020-07-07 11:13:53 +08:00
Zexi Li
279d1398cc Merge pull request #7062 from rainzm/automated-cherry-pick-of-#7061-upstream-release-3.3
Automated cherry pick of #7061: Update docker image onecloud-base and its references
2020-07-07 11:12:46 +08:00
Qiu Jian
eb342a70ab fix: remove default host list policy 2020-07-06 22:05:40 +08:00
rainzm
eb7b055ca2 Update docker image onecloud-base and its references 2020-07-06 21:00:22 +08:00
Qu Xuan
367d3f1470 fix: cloud poilcy count 2020-07-06 17:17:32 +08:00
Yousong Zhou
821283952d vpcagent: ClaimVpcGuestDnsRecords: guard against pending_deleted guests 2020-07-06 16:45:22 +08:00
Qu Xuan
e7cd84275e fix: 避免cloudprovider同步缺失 2020-07-06 16:27:06 +08:00
Zexi Li
4bd60ccd38 Merge pull request #7051 from zhaoxiangchun/automated-cherry-pick-of-#7046-upstream-release-3.3
Automated cherry pick of #7046: 增加influxdb的tag 的一些filter
2020-07-06 11:47:14 +08:00
Qu Xuan
79d0169855 fix: google rds regional and zonal 2020-07-06 11:18:25 +08:00
zhaoxiangchun
5db35871eb 增加influxdb的tag 的一些filter 2020-07-06 11:09:29 +08:00
Zexi Li
21d67a4297 Merge pull request #7043 from swordqiu/automated-cherry-pick-of-#7042-upstream-release-3.3
Automated cherry pick of #7042: feature: project filter that list jointable projects for user or group
2020-07-04 12:11:27 +08:00
Zexi Li
dcf4e3ebf2 Merge pull request #7032 from ioito/automated-cherry-pick-of-#7031-upstream-release-3.3
Automated cherry pick of #7031: fix: 避免azure同步资源组异常
2020-07-04 12:10:34 +08:00
Zexi Li
d15259cd5e Merge pull request #7037 from swordqiu/automated-cherry-pick-of-#7036-upstream-release-3.3
Automated cherry pick of #7036: fix: cloud account sync may block
2020-07-04 12:04:53 +08:00
Qiu Jian
b49272eb35 feature: project filter that list jointable projects for user or group 2020-07-04 11:35:13 +08:00
Qiu Jian
6133b1a5cc fix: cloud account sync may block 2020-07-04 10:23:39 +08:00
Qu Xuan
fcf1e193b9 fix: 避免azure同步资源组异常 2020-07-03 20:49:12 +08:00
Zexi Li
35f75db920 Merge pull request #7010 from ioito/automated-cherry-pick-of-#7009-upstream-release-3.3
Automated cherry pick of #7009: fix: 取消aliyun lb scheduler创建限制
2020-07-03 19:24:33 +08:00
Zexi Li
42ad035e56 Merge pull request #7030 from ioito/automated-cherry-pick-of-#7029-upstream-release-3.3
Automated cherry pick of #7029: fix: 避免slave zoneid异常
2020-07-03 19:23:55 +08:00
Qu Xuan
f303512a7c fix: 避免slave zoneid异常 2020-07-03 19:06:15 +08:00
Zexi Li
5ff0613ef3 Merge pull request #7026 from ioito/automated-cherry-pick-of-#7025-upstream-release-3.3
Automated cherry pick of #7025: fix: clouduser can_delete always be false
2020-07-03 18:43:37 +08:00
yunion-ci-robot
c5d448cbb3 Merge pull request #7028 from rainzm/automated-cherry-pick-of-#7027-upstream-release-3.3
Automated cherry pick of #7027: Update Dockerfile.ansibleserver
2020-07-03 18:33:44 +08:00
rainzm
69a4b12724 Update Dockerfile.ansibleserver 2020-07-03 18:22:59 +08:00
Zexi Li
b63dc0f91d Merge pull request #7021 from ioito/automated-cherry-pick-of-#7020-upstream-release-3.3
Automated cherry pick of #7020: fix: 优化安全组list速度,并发挥rule规则信息
2020-07-03 17:39:33 +08:00
Qu Xuan
acf641be26 fix: 同步不需要判断账号是否有iam权限 2020-07-03 17:38:09 +08:00
Qu Xuan
a54a9c05b1 fix: clouduser can_delete always be false 2020-07-03 17:18:58 +08:00
yunion-ci-robot
1ace096c5b Merge pull request #6987 from swordqiu/automated-cherry-pick-of-#6986-upstream-release-3.3
Automated cherry pick of #6986: fix: validate candiate ip for sync-fix-nics
2020-07-03 16:35:27 +08:00
Qu Xuan
dc3ef5c61e fix: 优化安全组list速度,并发挥rule规则信息 2020-07-03 15:53:02 +08:00
Zexi Li
5533d5131b Merge pull request #7003 from ioito/automated-cherry-pick-of-#6961-upstream-release-3.3
Automated cherry pick of #6961: fix: 优化sku同步逻辑
2020-07-03 11:40:19 +08:00
Zexi Li
31a4822aea Merge pull request #7019 from ioito/automated-cherry-pick-of-#7017-upstream-release-3.3
Automated cherry pick of #7017: fix: 修复cloudid同步问题
2020-07-03 11:39:12 +08:00
Qu Xuan
9c62343075 fix: 公有云子账号加域属性 2020-07-03 11:15:19 +08:00
Qu Xuan
544c19f3ce fix: 修复cloudid同步问题 2020-07-03 11:15:19 +08:00
yunion-ci-robot
7e30803175 Merge pull request #7002 from tb365/automated-cherry-pick-of-#7000-upstream-release-3.3
Automated cherry pick of #7000: cluster_d required->optional
2020-07-02 20:29:27 +08:00
Zexi Li
25c20ec6f8 Merge pull request #7004 from ioito/automated-cherry-pick-of-#6998-upstream-release-3.3
Automated cherry pick of #6998: fix: manager_id资源隔离获取
2020-07-02 20:20:35 +08:00
Zexi Li
4b2086e0b4 Merge pull request #7013 from zexi/automated-cherry-pick-of-#7012-upstream-release-3.3
Automated cherry pick of #7012: monitor: reduce subscription mysql usage
2020-07-02 20:19:25 +08:00
Zexi Li
220fc57201 Merge pull request #7007 from wanyaoqi/automated-cherry-pick-of-#7006-upstream-release-3.3
Automated cherry pick of #7006: bind mount nfs storage path
2020-07-02 17:35:25 +08:00
Zexi Li
de889ec6cc monitor: reduce subscription mysql usage 2020-07-02 17:34:26 +08:00
Qu Xuan
82d0f5c03f fix: 取消aliyun lb scheduler创建限制 2020-07-02 15:44:19 +08:00
wanyaoqi
5db73a6670 bind mount nfs storage path 2020-07-02 14:34:16 +08:00
Qu Xuan
66fc71cc81 fix: manager_id资源隔离获取 2020-07-02 14:27:53 +08:00
Qu Xuan
04427515fa fix: 优化sku同步逻辑 2020-07-02 14:26:46 +08:00
tangbin
87cf251d2d cluster_d required->optional 2020-07-02 11:55:15 +08:00
Zexi Li
029233a5a4 Merge pull request #6995 from rainzm/automated-cherry-pick-of-#6994-upstream-release-3.3
Automated cherry pick of #6994: fix: Override Master and Slave for scalinggroup_guest
2020-07-02 10:34:50 +08:00
Zexi Li
57ae145034 Merge pull request #6989 from rainzm/automated-cherry-pick-of-#6988-upstream-release-3.3
Automated cherry pick of #6988: update jsonutils
2020-07-02 10:34:20 +08:00
Zexi Li
6f72aadf39 Merge pull request #6997 from tb365/automated-cherry-pick-of-#6996-upstream-release-3.3
Automated cherry pick of #6996: copyright api update
2020-07-02 10:24:25 +08:00
tangbin
a3245195ab copyright api update 2020-07-01 20:02:25 +08:00
Zexi Li
eb6d0ed5f0 Merge pull request #6985 from lvyangyang/automated-cherry-pick-of-#6913-upstream-release-3.3
Automated cherry pick of #6913: add: region/openstack 迁移接入
2020-07-01 19:29:56 +08:00
Zexi Li
160a315d7b Merge pull request #6991 from rainzm/automated-cherry-pick-of-#6990-upstream-release-3.3
Automated cherry pick of #6990: fix the bug introduced in #6643
2020-07-01 19:26:28 +08:00
rainzm
23c76dc796 fix: Override Master and Slave for scalinggroup_guest 2020-07-01 17:23:59 +08:00
rainzm
9685684876 fix the bug introduced in #6643 2020-07-01 16:52:27 +08:00
rainzm
b4884e3dde update jsonutils 2020-07-01 16:32:03 +08:00
Zexi Li
22c915d617 Merge pull request #6968 from ioito/automated-cherry-pick-of-#6903-upstream-release-3.3
Automated cherry pick of #6903: fix: 修正项目映射同步
2020-07-01 16:29:55 +08:00
lvyangyang
386746365d add: region/openstack 迁移接入 2020-07-01 16:28:29 +08:00
Zexi Li
f97c397b13 Merge pull request #6983 from ioito/automated-cherry-pick-of-#6982-upstream-release-3.3
Automated cherry pick of #6982: fix: capability for cloudid
2020-07-01 14:36:54 +08:00
Qiu Jian
41a9d92421 fix: validate candiate ip for sync-fix-nics 2020-07-01 14:17:58 +08:00
Qu Xuan
781cc3ed6b fix: capability for cloudid 2020-07-01 11:21:10 +08:00
Zexi Li
f8938b819c Merge pull request #6973 from ioito/automated-cherry-pick-of-#6972-upstream-release-3.3
Automated cherry pick of #6972: fix: 修复cloudid问题
2020-06-30 23:08:10 +08:00
Zexi Li
87043ebb5c Merge pull request #6976 from wanyaoqi/automated-cherry-pick-of-#6975-upstream-release-3.3
Automated cherry pick of #6975: fix deploy backup server order
2020-06-30 23:07:28 +08:00
wanyaoqi
207cd93fe0 fix deploy backup server order 2020-06-30 22:02:40 +08:00
Qu Xuan
45819e6c12 fix: 避免未本地缓存usercache 2020-06-30 21:09:24 +08:00
Qu Xuan
223c9439b1 fix: 修复cloudid问题 2020-06-30 21:09:23 +08:00
Zexi Li
9fb62eb504 Merge pull request #6955 from wanyaoqi/automated-cherry-pick-of-#6954-upstream-release-3.3
Automated cherry pick of #6954: include system usage
2020-06-30 12:07:58 +08:00
Zexi Li
8842b97ca0 Merge pull request #6963 from ioito/automated-cherry-pick-of-#6962-upstream-release-3.3
Automated cherry pick of #6962: fix: 避免同步不到其他域的云账号
2020-06-30 12:06:42 +08:00
Zexi Li
5ecb97d532 Merge pull request #6967 from ioito/automated-cherry-pick-of-#6966-upstream-release-3.3
Automated cherry pick of #6966: fix: 修复权限组权限同步异常问题
2020-06-30 12:03:38 +08:00
Zexi Li
e20e308ac6 Merge pull request #6965 from swordqiu/automated-cherry-pick-of-#6964-upstream-release-3.3
Automated cherry pick of #6964: fix: reduce totp verification overhead
2020-06-30 12:01:39 +08:00
Zexi Li
10052eb330 Merge pull request #6971 from yousong/automated-cherry-pick-of-#6970-upstream-release-3.3
Automated cherry pick of #6970: cloudcommon: taskman: fix table insert
2020-06-30 11:59:57 +08:00
Yousong Zhou
986878289e cloudcommon: taskman: fix table insert
Fix the following error

	run error: reflect: NumField of non-struct type *taskman.STask

Fixes 08cd41b60d ("cloudcommon: taskman: SetModelManager")

Reported-by: Qu Xuan <quxuan@yunionyun.com>
2020-06-30 11:55:49 +08:00
Qu Xuan
e31334b471 fix: 支持同步project标签到本地资源 2020-06-30 11:51:26 +08:00
Qu Xuan
b25295bf03 fix: 修正项目映射同步 2020-06-30 11:51:26 +08:00
Qu Xuan
21a09d29d6 fix: 修复权限组权限同步异常问题 2020-06-30 10:55:23 +08:00
Zexi Li
5de04ebdf4 Merge pull request #6948 from swordqiu/automated-cherry-pick-of-#6947-upstream-release-3.3
Automated cherry pick of #6947: fix: disable domain sharing if non_default_domain_projects turned off
2020-06-30 10:48:18 +08:00
Qiu Jian
265bbc6e77 fix: reduce totp verification overhead 2020-06-30 02:32:25 +08:00
Qu Xuan
ef0242d15b fix: 避免同步不到其他域的云账号 2020-06-29 20:35:07 +08:00
Zexi Li
0d1826644b Merge pull request #6958 from yousong/automated-cherry-pick-of-#6957-upstream-release-3.3
Automated cherry pick of #6957: cloudcommon: taskman: SetModelManager
2020-06-29 19:36:59 +08:00
Zexi Li
77d1ac7056 Merge pull request #6956 from wanyaoqi/automated-cherry-pick-of-#6950-upstream-release-3.3
Automated cherry pick of #6950: - add server pending deleted for host details
2020-06-29 19:36:09 +08:00
Zexi Li
d20654575c Merge pull request #6953 from rainzm/automated-cherry-pick-of-#6952-upstream-release-3.3
Automated cherry pick of #6952: fix: Error occurs when suitableWire exists or all suitableNetwork exist.
2020-06-29 19:27:32 +08:00
Yousong Zhou
60293ef052 cloudcommon: tablespec: informer: use %#v to log bad obj
Fixes 145c88f79b ("cloudcommon: tablespec: informer: log obj type")
2020-06-29 14:47:14 +08:00
Yousong Zhou
db9789c868 cloudcommon: taskman: SetModelManager 2020-06-29 14:47:14 +08:00
wanyaoqi
8751082487 - add server pending deleted for host details
- host list by server networks

- guest networks return wire id
2020-06-29 11:41:00 +08:00
wanyaoqi
89ec83fec3 include system usage 2020-06-28 20:44:01 +08:00
rainzm
030a2edfb9 fix: Error occurs when suitableWire exists or all suitableNetwork exist. 2020-06-28 16:59:36 +08:00
Qiu Jian
a23f57da4d fix: disable domain sharing if non_default_domain_projects turned off 2020-06-28 13:25:38 +08:00
Zexi Li
561465e7e8 Merge pull request #6944 from yousong/automated-cherry-pick-of-#6943-upstream-release-3.3
Automated cherry pick of #6943: lb: include cluster name info in details
2020-06-28 09:01:37 +08:00
Yousong Zhou
5f49670e18 lb: include cluster name info in details 2020-06-24 18:54:10 +08:00
Zexi Li
fa521da2cd Merge pull request #6934 from wanyaoqi/automated-cherry-pick-of-#6933-upstream-release-3.3
Automated cherry pick of #6933: server name enable upper case
2020-06-24 17:42:22 +08:00
Zexi Li
fb0e4e093f Merge pull request #6919 from ioito/automated-cherry-pick-of-#6918-upstream-release-3.3
Automated cherry pick of #6918: fix: 避免azure同步项目失败
2020-06-24 12:59:34 +08:00
Zexi Li
6a64efb7e5 Merge pull request #6927 from ioito/automated-cherry-pick-of-#6926-upstream-release-3.3
Automated cherry pick of #6926: fix: google资源名称兼容处理
2020-06-23 23:29:32 +08:00
Zexi Li
2fa8e1b658 Merge pull request #6937 from swordqiu/automated-cherry-pick-of-#6936-upstream-release-3.3
Automated cherry pick of #6936: fix: sort quota list result by usage rate
2020-06-23 23:27:54 +08:00
Zexi Li
202f6b4be2 Merge pull request #6932 from swordqiu/automated-cherry-pick-of-#6931-upstream-release-3.3
Automated cherry pick of #6931: fix: keystone project resource count not accurate
2020-06-23 23:26:38 +08:00
Qiu Jian
9012180b60 fix: sort quota list result by usage rate 2020-06-23 22:23:34 +08:00
Zexi Li
33d9ef948a Merge pull request #6922 from swordqiu/automated-cherry-pick-of-#6921-upstream-release-3.3
Automated cherry pick of #6921: fix: simplify forbidden user login message
2020-06-23 21:25:58 +08:00
wanyaoqi
6f20638f8b server name enable upper case 2020-06-23 21:05:30 +08:00
Qiu Jian
161db6d95f fix: keystone project resource count not accurate 2020-06-23 21:03:30 +08:00
Qu Xuan
4f5a2ff433 fix: google资源名称兼容处理 2020-06-23 20:30:31 +08:00
Qiu Jian
611b9e9b5e fix: simplify forbidden user login message 2020-06-23 17:47:20 +08:00
Qu Xuan
f8cce28926 fix: 避免azure同步项目失败 2020-06-23 17:32:25 +08:00
Zexi Li
965b51c633 Merge pull request #6914 from wanyaoqi/automated-cherry-pick-of-#6904-upstream-release-3.3
Automated cherry pick of #6904: fix get storage capabilities with null field
2020-06-23 11:53:52 +08:00
Zexi Li
20443286f6 Merge pull request #6915 from ioito/automated-cherry-pick-of-#6912-upstream-release-3.3
Automated cherry pick of #6912: optimized: 支持ip和端口过滤安全组
2020-06-23 11:52:27 +08:00
Qu Xuan
f12192f1c4 optimized: 支持ip和端口过滤安全组 2020-06-23 11:26:09 +08:00
wanyaoqi
615fe1da8b fix get storage capabilities with null field 2020-06-23 10:54:27 +08:00
yunion-ci-robot
0ec55c87c1 Merge pull request #6907 from wanyaoqi/automated-cherry-pick-of-#6906-upstream-release-3.3
Automated cherry pick of #6906: disable dhclient
2020-06-22 23:42:03 +08:00
wanyaoqi
9a6c26de1c disable dhclient 2020-06-22 21:30:27 +08:00
Zexi Li
c44a8e0b77 Merge pull request #6894 from yousong/automated-cherry-pick-of-#6893-upstream-release-3.3
Automated cherry pick of #6893: cloudcommon: app: cosmetic change
2020-06-22 09:15:19 +08:00
Zexi Li
afaf9406e8 Merge pull request #6900 from yousong/automated-cherry-pick-of-#6899-upstream-release-3.3
Automated cherry pick of #6899: cloudcommon: tablespec: informer: log obj type
2020-06-22 09:10:18 +08:00
Yousong Zhou
f1dfcd5e06 keystone: passwords: SetModelManager
To quash avoid informer error "virtual object is nil"
2020-06-21 18:53:28 +08:00
Yousong Zhou
7d47ac4dd7 keystone: config: SetModelManager for whitelisted config
To quash avoid informer error "virtual object is nil"
2020-06-21 18:53:28 +08:00
Yousong Zhou
2f79c99dc7 cloudcommon: tablespec: informer: log obj type 2020-06-21 18:53:28 +08:00
Yousong Zhou
aeba29c4b3 cloudcommon: policy: fix interval and oneshot sync
Reduce CPU utilization caused by queued time.AfterFunc calls
2020-06-21 18:33:41 +08:00
Yousong Zhou
28e83a3125 cloudcommon: app: cosmetic change 2020-06-21 18:33:41 +08:00
Zexi Li
c991cdc76a Merge pull request #6823 from zhaoxiangchun/feature/zxc-unified-monitor
统一报警模块
2020-06-21 13:10:13 +08:00
Zexi Li
494893d717 Merge pull request #6001 from ioito/feature/qx-cloudid
Feature/qx cloudid
2020-06-21 13:09:48 +08:00
zhaoxiangchun
f20a87a5db Modify alert structure and inherit scoperesource 2020-06-21 12:18:22 +08:00
zhaoxiangchun
6c66185bd8 统一报警模块 2020-06-21 11:39:23 +08:00
Qu Xuan
a07b112be1 feature: CloudId服务支持 2020-06-21 11:30:01 +08:00
Zexi Li
b426505662 Merge pull request #6880 from swordqiu/feature/qj-allow-enabled-idp-synced-users
feature: 1. allow enable/disable idp-synced-users 2. turn off user's MFA by default
2020-06-21 11:24:03 +08:00
Zexi Li
83d906fae5 Merge pull request #6891 from yousong/bugfix/yousong-vpc-acl
vpcagent: different direction for l3 and l4 match
2020-06-21 11:23:44 +08:00
Zexi Li
ba8f52cfe2 Merge pull request #6864 from yousong/bugfix/yousong-lb-redirect
Bugfix/yousong lb redirect
2020-06-21 11:23:22 +08:00
yunion-ci-robot
32c34d2681 Merge pull request #6892 from zexi/hotfix/ignore-etcd-not-found-error
ignore common etcd endpoint not found error
2020-06-21 11:20:38 +08:00
Zexi Li
e9da1022b9 ignore common etcd endpoint not found error 2020-06-21 10:47:00 +08:00
yunion-ci-robot
fc8be0bb93 Merge pull request #6890 from wanyaoqi/feature/wyq/filter-by-cloudaccounts
feature: support filter by cloudaccounts
2020-06-20 23:56:23 +08:00
Yousong Zhou
97251c7cc9 vpcagent: different direction for l3 and l4 match 2020-06-19 19:42:58 +08:00
wanyaoqi
561d7b0cca support filter by cloudaccounts 2020-06-19 19:01:24 +08:00
Zexi Li
183180e178 Merge pull request #6879 from zexi/feature/lzx-suggest-refactor
monitor: refactor suggest code
2020-06-19 11:45:07 +08:00
yunion-ci-robot
2b18251a85 Merge pull request #6878 from yousong/bugfix/yousong-informer
opslog: LogEvent: set model manager
2020-06-19 10:23:23 +08:00
Zexi Li
995e5859ef monitor: refactor suggest code 2020-06-19 10:21:12 +08:00
Yousong Zhou
0038848609 mcclient: lb: allow empty string as arg for --redirect-{scheme,host,path} 2020-06-19 10:17:04 +08:00
Yousong Zhou
3fe10a7383 lb: onecloud: allow empty string for redirect_{scheme,host,path} 2020-06-19 10:17:04 +08:00
yunion-ci-robot
76014fbd7b Merge pull request #6865 from zexi/hotfix/disable-inform-not-init
informer: do not inform if backend not init
2020-06-19 10:08:20 +08:00
Yousong Zhou
4ce404dd8d vendor: update yunion.io/x/structarg 2020-06-19 10:06:58 +08:00
yunion-ci-robot
f08a9d748d Merge pull request #6883 from swordqiu/hotfix/qj-system-create-network-private
fix: network created by sysadmin should be shared by default
2020-06-19 09:50:14 +08:00
yunion-ci-robot
ca031b5913 Merge pull request #6885 from swordqiu/hotfix/qj-sync-disconnected-account
fix: wrong cloud provider status when sync disconnected cloud account
2020-06-19 09:49:08 +08:00
Qiu Jian
1d9a3f2731 fix: wrong cloud provider status when sync disconnected cloud account 2020-06-19 01:17:34 +08:00
yunion-ci-robot
f4faaa37e6 Merge pull request #6859 from yousong/bugfix/yousong-cloudaccount-sync
cloudaccounts: one sync task in queue per cloudaccount
2020-06-18 23:06:03 +08:00
yunion-ci-robot
21e4ca3852 Merge pull request #6881 from wanyaoqi/bugfix/wyq/fix-reserved-ip-export-keys
bugfix: fix reserved ip export keys
2020-06-18 22:51:04 +08:00
Qiu Jian
5c53ccc3d8 fix: network created by sysadmin should be shared by default 2020-06-18 22:39:28 +08:00
wanyaoqi
6af753c819 fix reserved ip export keys 2020-06-18 21:44:30 +08:00
Qiu Jian
2cf49c37dc feature: 1. allow enable/disable idp-synced-users 2. turn off user's MFA by default 2020-06-18 20:22:47 +08:00
yunion-ci-robot
08154fd0b0 Merge pull request #6869 from rainzm/notify/email_fix
Notify/email fix
2020-06-18 20:13:02 +08:00
Yousong Zhou
4bbf7c0484 opslog: remove unneeded nil check 2020-06-18 19:18:48 +08:00
Yousong Zhou
50449ca014 opslog: group literal fields 2020-06-18 19:17:28 +08:00
Yousong Zhou
fbc48c792b opslog: readability change 2020-06-18 19:12:48 +08:00
Yousong Zhou
be46546ba5 opslog: LogEvent: set model manager
Fix informer warning "object xx virtual object is nil"
2020-06-18 19:10:31 +08:00
Zexi Li
cb51df9491 Merge pull request #6871 from ioito/hotfix/qx-rds-sync-remove
fix: 避免同步删除失败
2020-06-18 19:05:26 +08:00
rainzm
109bdc05d8 fix: Fix problems about sending verify email 2020-06-18 19:03:13 +08:00
Yousong Zhou
8f5c65b923 cloudaccounts: one sync task in queue per cloudaccount 2020-06-18 17:11:36 +08:00
yunion-ci-robot
acbafe5a1c Merge pull request #6875 from tb365/bugfix/tb-err-not-found-fix
replace err with errors.cause
2020-06-18 15:13:07 +08:00
tangbin
6b8e37c88f replace err with errors.cause 2020-06-18 14:26:55 +08:00
Qu Xuan
3c75119c50 fix: 避免同步删除失败 2020-06-18 14:25:36 +08:00
rainzm
8ed4148fbb fix: Fix the url of 'notify-template-delete' in climc 2020-06-18 11:38:52 +08:00
Zexi Li
7c61e9662e informer: do not inform if backend not init 2020-06-18 11:08:26 +08:00
Zexi Li
eb5e902257 Merge pull request #6854 from tb365/bugfix/tb-bugfix-0617
rds postpaid instance create fix
2020-06-17 18:51:41 +08:00
Zexi Li
e751b1d4d2 Merge pull request #6861 from tb365/bugfix/tb-bugfix-ctyun-0607
shuzhou to suzhou
2020-06-17 18:50:44 +08:00
Zexi Li
4eee2e54ad Merge pull request #6839 from zexi/hotfix/scheduler-overcommit
scheduler: fix memory over committed
2020-06-17 18:49:08 +08:00
Zexi Li
0876ac9a22 Merge pull request #6838 from wanyaoqi/feature/wyq/configureable-reload-telegraf-config
host: configureable reload telegraf config
2020-06-17 18:35:15 +08:00
tangbin
8514e19102 shuzhou to suzhou 2020-06-17 15:51:19 +08:00
tangbin
6ecebc5f2b rds postpaid instance create fix 2020-06-17 15:39:37 +08:00
yunion-ci-robot
41f97d32fb Merge pull request #6837 from yousong/bugfix/yousong-putback
Bugfix/yousong putback
2020-06-17 11:26:00 +08:00
Yousong Zhou
358f5d41af appsrv: rework TestRing 2020-06-17 10:52:14 +08:00
Yousong Zhou
e37f15cac2 appsrv: ring: release ring content on pop 2020-06-17 10:52:14 +08:00
Zexi Li
5fda7e88b7 Merge pull request #6849 from swordqiu/hotfix/qj-disable-policy-rule-compaction
Hotfix/qj disable policy rule compaction
2020-06-17 10:28:47 +08:00
Qiu Jian
2efb7fc9e6 fix: policy allow if one of the matching rules is allow 2020-06-16 23:06:30 +08:00
Qiu Jian
818d40c08b fix: disable policy rule compaction 2020-06-16 22:36:00 +08:00
Zexi Li
12fe6b1c2d Merge pull request #6844 from wanyaoqi/bugfix/wyq/fix-cpu-usage-metrics
bugfix: fix cpu usage metrics
2020-06-16 20:53:23 +08:00
wanyaoqi
25310ed922 fix cpu usage metrics 2020-06-16 20:41:11 +08:00
Zexi Li
b2c232f75b Merge pull request #6824 from wanyaoqi/bugfix/wyq/win10
bugfix: fix windows install regedit record
2020-06-16 20:12:07 +08:00
Zexi Li
4535f887bb Merge pull request #6822 from wanyaoqi/bugfix/wyq/minor-fix-061220
fix host set reserved resource func name
2020-06-16 19:21:24 +08:00
Zexi Li
d8d6e8c5b5 scheduler: fix memory over committed 2020-06-16 18:51:13 +08:00
yunion-ci-robot
723ac0aee3 Merge pull request #6835 from yousong/bugfix/yousong-circleci
scripts/coverage.sh: ignore packages without test files
2020-06-16 15:08:00 +08:00
wanyaoqi
714b87aa39 configureable reload telegraf config 2020-06-16 14:52:18 +08:00
Yousong Zhou
200029dfd2 scripts/coverage.sh: ignore packages without test files
We have vet and build check available, no need to repeat them here
2020-06-16 12:52:20 +08:00
Yousong Zhou
e27a12ec61 guestdrivers: rework test 2020-06-16 12:52:20 +08:00
yunion-ci-robot
55255ef61b Merge pull request #6833 from yousong/bugfix/yousong-circleci
.circleci: run tests faster
2020-06-15 22:31:43 +08:00
Yousong Zhou
bf1b1f48b0 .circleci: run tests parallelly 2020-06-15 18:56:33 +08:00
Yousong Zhou
d4f54af5ad multicloud: speed up objectstore test 2020-06-15 18:56:33 +08:00
yunion-ci-robot
6cedfa30ff Merge pull request #6832 from yousong/bugfix/yousong-vendor
vendor: update yunion.io/x/{jsonutils.pkg}
2020-06-15 17:38:33 +08:00
yunion-ci-robot
e53cfa6322 Merge pull request #6778 from rainzm/vmware/init_network
feat: Support suggest network config before creating vmware cloud account
2020-06-15 17:37:29 +08:00
Zexi Li
4248961f96 Merge pull request #6828 from yousong/bugfix/yousong-lblistener-cert
lblistener: rename filter name certificate{,_id}
2020-06-15 17:36:56 +08:00
Yousong Zhou
a2fda726d1 vendor: update yunion.io/x/{jsonutils.pkg} 2020-06-15 17:17:49 +08:00
Yousong Zhou
458bd0c7f7 sysutils: rework test 2020-06-15 17:17:49 +08:00
Yousong Zhou
0208314075 multicloud: huawei: rework responses_test
- use json object Equals method for comparison
 - t.Fatalf on unexpected errors
2020-06-15 17:03:46 +08:00
Yousong Zhou
2a32627b55 cloudcommon: cmdline: rework test
Compare JSONObject with Equals
2020-06-15 16:49:12 +08:00
Zexi Li
7f9fb8d763 Merge pull request #6830 from ioito/hotfix/qx-metdata-list-optimized
fix: 优化标签列表version问题
2020-06-15 14:11:09 +08:00
Qu Xuan
d296a18011 fix: 优化标签列表version问题 2020-06-15 11:54:44 +08:00
Yousong Zhou
0f953b8b23 lblistener: rename filter name certificate{,_id}
Previously we accept both, now with structured input we'd better choose
one and ignore the other.  Use certificate_id because that's the
console's choice
2020-06-15 11:04:12 +08:00
wanyaoqi
9372a7b9c4 fix windows install regedit record 2020-06-15 10:56:47 +08:00
rainzm
14f324ea4a feat: Support suggest network config before create vmware cloud account 2020-06-12 17:00:37 +08:00
wanyaoqi
413d292c22 fix host set reserved resource func name 2020-06-12 16:10:05 +08:00
yunion-ci-robot
f4b7044767 Merge pull request #6817 from yousong/bugfix/yousong-odds
Bugfix/yousong odds
2020-06-12 10:10:20 +08:00
Yousong Zhou
173448ee43 guestnetworks: reduce odds of collision seeded by epoch seconds 2020-06-11 21:19:16 +08:00
Yousong Zhou
6a63aa9429 guestnetworks: use math/rand instead of crypto/rand 2020-06-11 21:14:34 +08:00
Zexi Li
c55ae8e3bc Merge pull request #6774 from zexi/feature/add-service-usages
apigateway: expose identity/image/k8s usage rpc method
2020-06-11 18:07:37 +08:00
Zexi Li
33de484f3d Merge pull request #6808 from ioito/hotfix/qx-rds-sku-filter
fix: 避免sql erorr
2020-06-11 17:51:55 +08:00
Zexi Li
9c8b7b6237 Merge pull request #6810 from ioito/hotfix/qx-openstack-disk-sync
fix: 避免openstack磁盘和存储窜位
2020-06-11 17:51:38 +08:00
Zexi Li
984ea4cd31 Merge pull request #6811 from rainzm/scheduledtask/fix
Scheduledtask/fix
2020-06-11 17:51:09 +08:00
Zexi Li
6b4e5e3806 Merge pull request #6803 from zexi/hotfix/webconsole-misc-handlers
webconsole: fix version and others handler not handle
2020-06-11 17:49:56 +08:00
yunion-ci-robot
8853686624 Merge pull request #6816 from zexi/hotfix/heap-large-usage
fix informer worker heap large usage
2020-06-11 17:21:15 +08:00
Zexi Li
cc5f731fc3 fix informer worker heap large usage 2020-06-11 16:00:06 +08:00
rainzm
3e7a5acb9b fix: Support to set the label of scheduledtask to Chinese 2020-06-11 12:57:33 +08:00
rainzm
0dad8351d3 fix: Add zero padding in front of execution time for scheduledtask 2020-06-11 12:06:21 +08:00
Qu Xuan
4e48d33ecf fix: 避免openstack磁盘和存储窜位 2020-06-11 11:32:22 +08:00
Qu Xuan
aa0d05ccd4 fix: 避免sql erorr 2020-06-11 10:41:04 +08:00
Zexi Li
e49c11edb2 Merge pull request #6802 from rainzm/scheduledtask/filter
fix the tag filter and result record for scheduledtask
2020-06-10 17:26:09 +08:00
Zexi Li
d54f18541f Merge pull request #6797 from wanyaoqi/bugfix/wyq/fix-host-list-filter
fix host list servers filter
2020-06-10 17:05:29 +08:00
Zexi Li
e56152aa48 webconsole: fix version and others handler not handle 2020-06-10 16:57:28 +08:00
rainzm
5f2a91f2af fix the tag filter and result record for scheduledtask 2020-06-10 16:17:34 +08:00
wanyaoqi
1b055f24a9 fix host list servers filter 2020-06-10 14:05:33 +08:00
yunion-ci-robot
2f210ae41d Merge pull request #6765 from yousong/feature/yousong-default-params
Feature/yousong default params
2020-06-10 11:30:08 +08:00
Zexi Li
c7d011946d Merge pull request #6786 from rainzm/fix/syncclouddisks
fix: Hanle the error of vdisk.GetIStorage in syncCloudDisk
2020-06-10 11:27:36 +08:00
yunion-ci-robot
8646141dff Merge pull request #6663 from ioito/hotfix/qx-secgroup-sync-optimized
fix: 优化安全组同步逻辑
2020-06-10 11:18:08 +08:00
Zexi Li
0fe9dd33d3 Merge pull request #6717 from yousong/feature/yousong-vpc-dns
Feature/yousong vpc dns
2020-06-10 11:16:10 +08:00
Zexi Li
ebee8b91a2 Merge pull request #6779 from ioito/hotfix/qx-huawei-cloudevent-succ
fix: 更正华为云操作成功判断
2020-06-10 10:45:46 +08:00
Zexi Li
c5958186f9 Merge pull request #6775 from yousong/bugfix/yousong-network
Bugfix/yousong network
2020-06-10 10:20:18 +08:00
Zexi Li
02fc819d09 Merge pull request #6782 from rainzm/notify/version
fix: Add '/version' handler for notify
2020-06-10 10:18:49 +08:00
Zexi Li
0b3afdd29c Merge pull request #6791 from swordqiu/hotfix/qj-policy-explain-rework
fix: policy-explain not working properly
2020-06-10 09:52:27 +08:00
Qiu Jian
5ebb18b691 fix: policy-explain not working properly 2020-06-09 22:17:35 +08:00
Yousong Zhou
07ae9c12ed lblisteners: list: filter with certificate ids 2020-06-09 20:08:25 +08:00
Yousong Zhou
b4ce651094 mcclient: options: lb: arg rename cluster{,_id}
Ref b0537773cd ("fxi: 修复lb 有些有vpc_id为空的问题")
2020-06-09 20:08:25 +08:00
Yousong Zhou
258aba2504 lbagents: add check on vrrp.advert_int 2020-06-09 20:08:25 +08:00
Yousong Zhou
57e29330be lbagents: params: add needsUpdatePeer() and updateBy() methods 2020-06-09 20:08:25 +08:00
Yousong Zhou
1dc312303c lbbackends: allow backends of the same region (vs. zone) 2020-06-09 20:08:25 +08:00
Yousong Zhou
333954add9 climc: lbagent-show-default-params: add --cluster option support 2020-06-09 20:08:25 +08:00
Yousong Zhou
71e9f99b65 lbagent: default-params: default vrrp params from peer lbagents 2020-06-09 20:08:25 +08:00
rainzm
4c6682617c fix: Hanle the error of vdisk.GetIStorage in syncCloudDisk 2020-06-09 19:45:46 +08:00
rainzm
2cd2f3d029 fix: Add '/version' handler for notify 2020-06-09 18:45:54 +08:00
Qu Xuan
5837b696d7 fix: 更正华为云操作成功判断 2020-06-09 18:19:57 +08:00
yunion-ci-robot
f441306d80 Merge pull request #6691 from rainzm/scheduledtasks/init
Scheduledtasks/init
2020-06-09 17:06:07 +08:00
Zexi Li
a8e5759523 Merge pull request #6777 from zexi/feature/expose-tablespec-interface
cloudcommon: expose ITableSpec function
2020-06-09 16:19:23 +08:00
Zexi Li
10603b4f64 cloudcommon: expose ITableSpec function 2020-06-09 16:16:24 +08:00
Yousong Zhou
0280b6aa5e networks: validate that start, end, gateway ip are in the same subnet 2020-06-09 16:10:06 +08:00
Yousong Zhou
f4a001ad65 networks: validateUpdateData: eliminate intermediate vars 2020-06-09 16:09:48 +08:00
Yousong Zhou
927cbd4156 networks: decrease indent 2020-06-09 16:09:48 +08:00
Yousong Zhou
f27e177274 networks: sep check of masklen only for start,end type creation 2020-06-09 16:09:48 +08:00
rainzm
3ea4beeb8e feat: Add 'ScheduledTaskQueueSize' options 2020-06-09 15:54:35 +08:00
rainzm
8a69558c86 Add 'trigger' for ScheduledTask 2020-06-09 15:54:35 +08:00
rainzm
2b7bd7a123 feat: Add climc command for ScheduledTask and ScheduledTaskActivity 2020-06-09 15:54:35 +08:00
rainzm
8d30ef0ad9 feat: Detach ScheduledTask when pending delete guest 2020-06-09 15:54:35 +08:00
rainzm
d6c5c29c62 feat: Add handers and table for ScheduledTask... 2020-06-09 15:54:35 +08:00
rainzm
058cc4fdce feat: Add ScheduledTask, ScheduledTaskActivity and ScheduledTaskLabel 2020-06-09 15:54:32 +08:00
Zexi Li
686cc78247 apigateway: expose identity/image/k8s usage rpc method 2020-06-09 13:32:53 +08:00
Zexi Li
14910fc051 Merge pull request #6772 from swordqiu/hotfix/qj-disable-update-zone-id
fix: disable updating zone_id for host, storage, wire
2020-06-09 00:11:46 +08:00
Qiu Jian
1e4acedf25 fix: disable updating zone_id for host, storage, wire 2020-06-08 21:58:59 +08:00
yunion-ci-robot
5d17bf653a Merge pull request #6769 from zexi/hotfix/ensure-influxdb-endpoint
region: retry set influxdb policy until completed
2020-06-08 21:11:09 +08:00
rainzm
8a2e23fd45 feat: Extract STimer from SScalingTimer 2020-06-08 21:01:16 +08:00
rainzm
7e80ecf61b fix: Wait for ticker when get status is wrong 2020-06-08 21:01:16 +08:00
Zexi Li
8e51f627a6 region: retry set influxdb policy until completed 2020-06-08 19:05:30 +08:00
yunion-ci-robot
232077b09b Merge pull request #6764 from yousong/bugfix/yousong-vendoring
vendor: update yunion.io/x/sqlchemy
2020-06-08 16:22:07 +08:00
yunion-ci-robot
a4b44d040b Merge pull request #6629 from zhaoxiangchun/feature/zxc-unified-monitor
统一监控接口
2020-06-08 16:16:07 +08:00
Yousong Zhou
2e687997ae vendor: update yunion.io/x/sqlchemy 2020-06-08 16:13:09 +08:00
yunion-ci-robot
ec12f1916e Merge pull request #6756 from rainzm/caller/handler_error
fix: handler param.convert's error in caller.go
2020-06-08 16:09:07 +08:00
yunion-ci-robot
7e2ade11ee Merge pull request #6763 from swordqiu/hotfix/qj-explain-rpc-piggyback-owner-privilige
fix: explainPolicy piggyback owner's privilige
2020-06-08 16:07:08 +08:00
yunion-ci-robot
ed00dbbfdd Merge pull request #6760 from wanyaoqi/bugfix/wyq/image-support-generate-name
bugfix: image support generate name
2020-06-08 15:51:48 +08:00
yunion-ci-robot
734d7e9994 Merge pull request #6648 from zexi/feature/db-resource-informer
implement generic service informer
2020-06-08 14:58:49 +08:00
Qu Xuan
03a3dfcd73 fix: 优化安全组同步逻辑 2020-06-08 14:10:38 +08:00
Zexi Li
9f4d4a450e refactor ITableSpec signature with context 2020-06-08 11:31:00 +08:00
wanyaoqi
a3043520ec image support generate name 2020-06-08 11:25:20 +08:00
rainzm
c793746f0d fix: handler param.convert's error in caller.go 2020-06-08 10:44:26 +08:00
Qiu Jian
e7b198ab35 fix: explainPolicy piggyback owner's privilige 2020-06-08 10:23:40 +08:00
zhaoxiangchun
86e687015f 修改框架查询influxdb的时间单位
epoch=ms,与以前虚拟机监控时间单位进行统一
2020-06-08 10:06:00 +08:00
Zexi Li
7a1d504e82 Merge pull request #6750 from swordqiu/hotfix/qj-base64-decode-invalid-password
fix: base64 decode 12-bytes plain text password return nil
2020-06-08 09:13:04 +08:00
Zexi Li
d1d22453bc Merge pull request #6755 from yousong/feature/yousong-default-params
Feature/yousong default params
2020-06-06 12:22:21 +08:00
yunion-ci-robot
190ac44566 Merge pull request #6757 from swordqiu/hotfix/qj-remove-name-space
fix: remove spaces in name
2020-06-06 12:21:45 +08:00
Qiu Jian
a51d554d74 fix: base64 decode 12-bytes plain text password return nil 2020-06-06 11:06:52 +08:00
yunion-ci-robot
bc841680e0 Merge pull request #6692 from ioito/hotfix/qx-object-acl
fix: 返回object默认acl
2020-06-06 10:58:47 +08:00
Qiu Jian
06e19c494c fix: remove spaces in name 2020-06-06 10:51:48 +08:00
yunion-ci-robot
7bfd4b572a Merge pull request #6734 from tb365/feature/tb-cancel-condition-release
cancel condition release
2020-06-05 17:17:43 +08:00
Zexi Li
749e99b5f9 Merge pull request #6754 from swordqiu/hotfix/qj-oss-upload-set-acl
fix: oss-upload fail to set object acl
2020-06-05 17:14:48 +08:00
Yousong Zhou
e8b6803525 climc: add command lbagent-show-default-params 2020-06-05 16:43:34 +08:00
Yousong Zhou
d4416f614f mcclient: options: add EmptyOption 2020-06-05 16:43:34 +08:00
Yousong Zhou
2b98f75c75 lbagent: new API: GET /loadbalanceragents/default-params 2020-06-05 16:01:37 +08:00
yunion-ci-robot
655362b34f Merge pull request #6752 from lvyangyang/feature/implement-allowDisableWrapLine
climc:allow disable term line width
2020-06-05 15:57:44 +08:00
Yousong Zhou
ce741a24cd lb: onecloud: disallow creating lb with vpc network 2020-06-05 15:36:56 +08:00
Qiu Jian
d519a6584b fix: oss-upload fail to set object acl 2020-06-05 15:32:15 +08:00
root
0a0af5cfa2 climc:allow disable term line width 2020-06-05 14:15:34 +08:00
Qu Xuan
510eb101ec fix: 返回object默认acl 2020-06-05 10:58:46 +08:00
yunion-ci-robot
db91628f0b Merge pull request #6730 from yousong/feature/yousong-lbcluster
Feature/yousong lbcluster
2020-06-04 22:36:10 +08:00
Zexi Li
593b69e436 Merge pull request #6740 from swordqiu/hotfix/qj-xsky-recode-using-wrong-info
fix: xsky recode using endpoint as accesskey key
2020-06-04 21:40:50 +08:00
Zexi Li
e532f46f0d Merge pull request #6736 from rainzm/gt/sfguest/generate
fix: Support 'generate_name' when saving template from guest
2020-06-04 21:39:39 +08:00
Zexi Li
6d76cc2af4 Merge pull request #6737 from tb365/bugfix/tb-bugfix-0604
ctyun sync host wire fix
2020-06-04 21:39:05 +08:00
Zexi Li
a5d47f4513 Merge pull request #6744 from wanyaoqi/bugfix/wyq/bind-mount-local-image-path
bugfix: bind mount local image path to container path
2020-06-04 21:24:00 +08:00
Qiu Jian
de081a768d fix: xsky recode using endpoint as accesskey key 2020-06-04 19:02:21 +08:00
tangbin
7e95750408 cancel condition release 2020-06-04 18:56:13 +08:00
tangbin
f58a9305e5 ctyun sync host wire fix 2020-06-04 18:48:35 +08:00
rainzm
27f746eb26 fix: Support 'generate_name' when saving template from guest 2020-06-04 18:27:41 +08:00
Yousong Zhou
1a308442c5 climc: lb-update: add --cluster argument 2020-06-04 15:58:06 +08:00
Yousong Zhou
74e19af514 climc: lbcluster-create: mark --zone as required 2020-06-04 15:58:06 +08:00
Yousong Zhou
5395210873 lb: allow update cluster_id with PUT request 2020-06-04 15:58:06 +08:00
Zexi Li
0d759322af Merge pull request #6728 from ioito/hotfix/qx-openstack-session
fix: 避免openstack session==nil
2020-06-04 15:04:13 +08:00
wanyaoqi
8e4668213e bind mount local image path to container path 2020-06-04 14:51:48 +08:00
Qu Xuan
90aa834942 fix: 避免openstack session==nil 2020-06-04 11:23:19 +08:00
Zexi Li
d50acbf3dd Merge pull request #6722 from ioito/hotfix/qx-region-city
fix: 添加region翻译
2020-06-04 10:27:51 +08:00
Zexi Li
866da0e6b0 Merge pull request #6726 from swordqiu/hotfix/qj-default-user-fetcher
fix: keystone event list fail to find user
2020-06-04 10:26:46 +08:00
Qiu Jian
b917ea6a10 fix: keystone event list fail to find user 2020-06-04 07:56:56 +08:00
Qu Xuan
6ba9a8fae8 fix: 添加region翻译 2020-06-03 20:39:00 +08:00
Zexi Li
3e182fb89b Merge pull request #6720 from ioito/hotfix/qx-object-escape
fix: 修复gcp object编码问题
2020-06-03 20:07:36 +08:00
Yousong Zhou
ba0e41d995 vpcagent: ovn: claim dnsrecords for all vpcs 2020-06-03 18:48:24 +08:00
Yousong Zhou
583718014c vpcagent: models: include dnsrecords 2020-06-03 18:25:59 +08:00
Yousong Zhou
88095c6d82 vpcagent: ovn: dns records for guest names 2020-06-03 18:25:59 +08:00
Yousong Zhou
d51791396f vpcagent: ovn: mark and sweep dns records 2020-06-03 18:25:59 +08:00
Zexi Li
01f53df8c3 Merge pull request #6711 from ioito/hotfix/qx-azure-classic-vm
fix: 移除默认调度策略
2020-06-03 17:27:25 +08:00
Zexi Li
5f1801202d Merge pull request #6696 from tb365/feature/tb-add-enterprise-info-update-climc
add-enterprise-info-update-climc
2020-06-03 17:26:13 +08:00
Zexi Li
73bcfb4bb7 Merge pull request #6713 from wanyaoqi/bugfix/wyq/fix-find-no-such-file
bugfix: isolated device manager:
2020-06-03 17:25:02 +08:00
Zexi Li
39244cce50 Merge pull request #6364 from yousong/feature/yousong-eip
Feature/yousong eip
2020-06-03 17:23:24 +08:00
Zexi Li
059b9388bd Merge pull request #6701 from yousong/feature/yousong-lb-selective-redirect
Feature/yousong lb selective redirect
2020-06-03 17:23:07 +08:00
Qu Xuan
c706821a74 fix: 修复gcp object编码问题 2020-06-03 16:35:31 +08:00
wanyaoqi
44cbdd07a3 isolated device manager:
- fix find boot_vga got No such file or dirtory
2020-06-03 15:46:25 +08:00
Qu Xuan
c2ce0460a2 fix: 移除默认调度策略 2020-06-03 15:03:20 +08:00
Zexi Li
7873fa5de3 Merge pull request #6708 from ioito/hotfix/qx-gcp-rds-err
fix: 转换gcp错误
2020-06-03 13:03:17 +08:00
Qu Xuan
9069814b17 fix: 转换gcp错误 2020-06-03 11:56:01 +08:00
Yousong Zhou
b6110fd3a1 lbbackend: kvm: allow adding 'host',"ip" backend type
For "host" type, as long as the requesting user can get access to it's
id and the validator plus userCred allows it
2020-06-03 11:34:29 +08:00
Yousong Zhou
97c5afda57 lbbackend: ValidateCreateLoadbalancerBackendData: use httperrors 2020-06-03 11:34:04 +08:00
Zexi Li
bbbc488a07 Merge pull request #6699 from rainzm/notify/verify
feat: Logo and copyright in verify email are same with these in company info
2020-06-03 10:17:34 +08:00
Zexi Li
bc02ef1992 Merge pull request #6702 from ioito/hotfix/qx-gcp-rds-user
fix: gcp默认创建允许所有地址访问的用户
2020-06-03 10:17:07 +08:00
Zexi Li
9de500f27c Merge pull request #6704 from ioito/hotfix/qx-vpc-create
fix: 允许gcp创建vpc时不指定cidr
2020-06-03 10:16:40 +08:00
Zexi Li
4fa1025329 Merge pull request #6706 from ioito/hotfix/qx-tenant-cache
fix: 避免越过tenantcache过期检查
2020-06-03 10:16:00 +08:00
yunion-ci-robot
d8eb8bc1d4 Merge pull request #6668 from swordqiu/hotfix/qj-get-property-support-rbac
fix: class method GetPropertyXXX should support rbac
2020-06-03 10:13:06 +08:00
Qu Xuan
8754ef2436 fix: 避免越过tenantcache过期检查 2020-06-02 22:17:28 +08:00
Qu Xuan
53d771025e fix: 允许gcp创建vpc时不指定cidr 2020-06-02 21:57:35 +08:00
Qu Xuan
f73b3ed03f fix: gcp默认创建允许所有地址访问的用户 2020-06-02 21:45:47 +08:00
Yousong Zhou
856310331f lblistenerrule: allow turning on/off redirect 2020-06-02 21:44:25 +08:00
Yousong Zhou
2cd6c85882 lblistenerrule: redirect: try avoid endless redirect 2020-06-02 21:44:25 +08:00
Yousong Zhou
471755103d lblistener: allow turning on/off redirect 2020-06-02 21:44:25 +08:00
Zexi Li
0d5be52f45 Merge pull request #6697 from swordqiu/hotfix/qj-esxiagent-service
fix: apigateway expose esxiagent service avaiability
2020-06-02 21:20:12 +08:00
Yousong Zhou
d3313eba42 lblistener: redirect: try avoid endless redirect 2020-06-02 21:17:20 +08:00
Yousong Zhou
d55af7af26 lblistenerrule: allow creation even for redirect listener 2020-06-02 21:17:17 +08:00
Yousong Zhou
ea8cd6d7e9 climc: lblistener-create: make --scheduler an optional arg 2020-06-02 21:17:17 +08:00
Yousong Zhou
473932311b lblistener: make scheduler an optional arg on creation 2020-06-02 21:17:17 +08:00
Yousong Zhou
3ae45d55eb lbagent: fix condition for "nothing to serve" 2020-06-02 21:17:17 +08:00
Yousong Zhou
7e2273bfbf lbagent: standalone rate control between listener and its rules 2020-06-02 21:17:17 +08:00
Yousong Zhou
3d58d51abe lbagent: decouple rule redirect from listener redirect 2020-06-02 21:17:17 +08:00
rainzm
156ef6bd2e feat: Logo and copyright in verify email are same with these in company
info
2020-06-02 20:52:06 +08:00
Qiu Jian
ddc483509a fix: apigateway expose esxiagent service avaiability 2020-06-02 20:30:07 +08:00
tangbin
bb808bd8aa add-enterprise-info-update-climc 2020-06-02 20:13:49 +08:00
yunion-ci-robot
0f9df3ed28 Merge pull request #6686 from ioito/bugfix/qx-secgroup
fix: 避免锁超时
2020-06-02 13:59:42 +08:00
Qu Xuan
a519a66122 fix: 避免锁超时 2020-06-02 11:10:01 +08:00
Zexi Li
e8d4655583 Merge pull request #6680 from ioito/hotfix/qx-s3-bucket-syncstatus
fix: sync s3 bucket status
2020-06-02 10:04:53 +08:00
Zexi Li
ad50e349f6 Merge pull request #6684 from ioito/hotfix/qx-google-object-acl
fix: gcp path escape for object
2020-06-02 10:04:34 +08:00
Zexi Li
7df836d0e8 Merge pull request #6666 from ioito/hotfix/qx-rule-project-id
fix: 安全组规则返回项目id信息
2020-06-02 10:03:08 +08:00
Zexi Li
dcb947cfa7 Merge pull request #6664 from zhaoxiangchun/feature/zxc-suggest-amount
在优化建议资源列表中增加费用信息
2020-06-02 10:02:26 +08:00
Zexi Li
0098d7ef41 Merge pull request #6675 from ioito/hotfix/qx-gcp-region
fix: add us-west4 for google region
2020-06-02 09:59:41 +08:00
Zexi Li
46266b392d Merge pull request #6670 from wanyaoqi/bugfix/wyq/get-snapshots-order-by-created-at
bugfix: get snapshots order by created at asc
2020-06-02 09:57:37 +08:00
Qu Xuan
23df2235e4 fix: gcp path escape for object 2020-06-01 19:57:07 +08:00
Qu Xuan
7cb40ec3c2 fix: sync s3 bucket status 2020-06-01 18:44:23 +08:00
Qu Xuan
1997e41ea6 fix: add us-west4 for google region 2020-06-01 18:25:35 +08:00
zhaoxiangchun
ecd4a94079 监控数据查询增加对任意时间范围的支持 2020-06-01 17:01:39 +08:00
zhaoxiangchun
3f63e4737a 统一监控接口
1.通过前端选择measurement等数据完成对influxdb指标的的查询
2.支持同时查询多个query。
2020-06-01 17:01:39 +08:00
Qiu Jian
a99deb6141 fix: class method GetPropertyXXX should support rbac 2020-06-01 15:52:58 +08:00
wanyaoqi
6e0f4a4947 get snapshots order by created at asc 2020-06-01 15:07:33 +08:00
Qu Xuan
61ff1544ec fix: 安全组规则返回项目id信息 2020-05-29 20:47:17 +08:00
Zexi Li
95a58cc606 implement generic service informer 2020-05-29 19:59:34 +08:00
zhaoxiangchun
585385f0cb 在优化建议资源列表中增加费用信息
另外,在资源进行处理时记录对应的status信息
2020-05-29 19:39:02 +08:00
Zexi Li
9307660d11 Merge pull request #6661 from rainzm/notify/remove_mobile_template
fix(notify): Remove default mobile template
2020-05-29 19:32:17 +08:00
Zexi Li
f5004eecc6 Merge pull request #6658 from ioito/hotfix/qx-bucket-fix
fix: byte size fix
2020-05-29 19:14:17 +08:00
rainzm
9374c65a8f fix(notify): Remove default mobile template 2020-05-29 18:48:02 +08:00
Qu Xuan
5ed624d15d fix: byte size fix 2020-05-29 16:58:56 +08:00
Zexi Li
f0a0eb4f54 Merge pull request #6564 from tb365/feature/tb-condition-release-2
redis&rds add postpaid duration
2020-05-29 14:21:58 +08:00
Zexi Li
10deea02d8 Merge pull request #6636 from swordqiu/hotfix/qj-get-matched-policysets
fix: ignore match weights when searching matched policysets
2020-05-29 14:20:13 +08:00
Zexi Li
581a5789cc Merge pull request #6650 from wanyaoqi/bugfix/wyq/fix-migrate-with-multi-storage
bugfix: fix migrate with multi local storage
2020-05-29 14:18:36 +08:00
wanyaoqi
4d404e09d0 fix migrate with multi local storage 2020-05-29 11:45:51 +08:00
Qiu Jian
0157028465 fix: ignore match weights when searching matched policysets 2020-05-29 10:01:20 +08:00
Zexi Li
4362927d23 Merge pull request #6642 from swordqiu/hotfix/qj-bucket-api-documentation
fix: generating bucket APIs
2020-05-29 01:39:49 +08:00
tangbin
346d558505 redis&rds add postpaid duration 2020-05-28 20:46:07 +08:00
yunion-ci-robot
61e56d5079 Merge pull request #6643 from rainzm/notify/domain
feat(notify): Support 'socpe:domain' when list contacts
2020-05-28 19:04:00 +08:00
yunion-ci-robot
83f5c3bb74 Merge pull request #6631 from swordqiu/hotfix/qj-host-convert-baremetal-sched-fail
fix: sysadmin cannot convert host in non-default domain
2020-05-28 19:02:00 +08:00
yunion-ci-robot
fde7f2dfa3 Merge pull request #6544 from zhaoxiangchun/bugfix/zxc-suggest-mon
类型是onecloud的notifier额外增加webconsole的alert
2020-05-28 18:59:00 +08:00
yunion-ci-robot
ab71537f5d Merge pull request #6646 from wanyaoqi/bugfix/wyq/minor-fix0528
bugfix: guesthandler declear variable and define
2020-05-28 18:46:59 +08:00
Qiu Jian
5e77a9682e fix: generating bucket APIs 2020-05-28 18:13:36 +08:00
Zexi Li
e7df5dba93 Merge pull request #6632 from zhaoxiangchun/bugfix/zxc-resource-mon
修复优化建议资源列表cloudenv过滤失效的问题
2020-05-28 18:06:55 +08:00
wanyaoqi
8fde0c62a4 declear variable and define 2020-05-28 18:04:46 +08:00
Zexi Li
e67aaa0585 Merge pull request #6637 from ioito/hotfix/qx-guest-create
fix: 避免因磁盘数量导致创建机器失败
2020-05-28 17:13:36 +08:00
Zexi Li
54309630c3 Merge pull request #6628 from wanyaoqi/feature/wyq/clean-network-scripts-on-init
host: clean network scripts on init
2020-05-28 16:17:23 +08:00
Yousong Zhou
e442e7a259 vpcagent: ovn: apply qos on eip 2020-05-28 15:51:21 +08:00
Yousong Zhou
4b44f21abf vpcagent: ovn: apply guestnetwork bw_limit
For kernel datapath, this requires at least openvswitch 2.10, or linux
4.15
2020-05-28 15:51:21 +08:00
Yousong Zhou
4b299846de vpcagent: ovn: use FindXxxReferrer_yyy 2020-05-28 15:51:21 +08:00
Yousong Zhou
5ad06097c1 vendor: update yunion.io/x/ovsdb 2020-05-28 15:51:21 +08:00
Yousong Zhou
2353396013 build: docker: use openvswitch:2.10.4-0 2020-05-28 15:51:21 +08:00
Yousong Zhou
df3c337bf6 elasticips: onecloud: support changing bandwidth 2020-05-28 15:51:21 +08:00
Yousong Zhou
91defab40f iproute2: route: add del funcs 2020-05-28 15:51:21 +08:00
Yousong Zhou
6900393095 iproute2: errors: add IsErrSrch() 2020-05-28 15:51:21 +08:00
Yousong Zhou
a5c253e129 iproute2: route: prepare for route del 2020-05-28 15:51:21 +08:00
Yousong Zhou
d714e450fb hostman: options: add option --ovn-underlay-mtu 2020-05-28 15:51:21 +08:00
Yousong Zhou
61659d7b28 hostman: options: add option --sdn-pid-file 2020-05-28 15:51:20 +08:00
Yousong Zhou
25d05899d4 hostman: options: knobs for enabling features in sdnagent 2020-05-28 15:51:20 +08:00
Yousong Zhou
2841e245e2 vpcagent: ovn: set underlay mtu size in config file 2020-05-28 15:51:20 +08:00
Yousong Zhou
83a44ce94c vpcagent: ovn: mix eipgw and distgw 2020-05-28 15:51:20 +08:00
Yousong Zhou
822ba58756 vpcagent: models: include elasticip 2020-05-28 15:51:20 +08:00
Yousong Zhou
22090a3790 vpcagent: ovn: add and use mac.HashVpcHostDistgwMac() 2020-05-28 15:51:20 +08:00
Yousong Zhou
eaa16f3335 climc: shell: networks: add eip to server type choices 2020-05-28 15:51:20 +08:00
Yousong Zhou
56c89ed577 climc: eip-create: make manager, region optional arguments 2020-05-28 15:51:20 +08:00
Yousong Zhou
7e02808c86 guests: support server-create-eip for onecloud guests and eip 2020-05-28 15:51:20 +08:00
Yousong Zhou
df4d80fbd9 guests: list usable guests for specified eip 2020-05-28 15:51:20 +08:00
Yousong Zhou
2390e352f8 elasticips: list usable eips for onecloud kvm guests 2020-05-28 15:51:20 +08:00
Yousong Zhou
18fe12a4a7 elasticips: onecloud: support sync and syncstatus 2020-05-28 15:51:20 +08:00
Yousong Zhou
74920a37e1 tasks: onecloud: support disassociate eip 2020-05-28 15:51:20 +08:00
Yousong Zhou
8b82d67b6d guestdrivers: kvm: eip associate 2020-05-28 15:51:20 +08:00
Yousong Zhou
ff6e3e2367 guestnetworks: add EipId field 2020-05-28 15:51:20 +08:00
Yousong Zhou
3254646244 elasticips: onecloud: create op 2020-05-28 15:51:20 +08:00
Yousong Zhou
fa833e6948 elasticips: onecloud: delete op for non-managed eip 2020-05-28 15:39:06 +08:00
Yousong Zhou
8e1b6ded3e elasticips: make manager, region arguments optional 2020-05-28 15:39:06 +08:00
Yousong Zhou
0bf41caa36 elasticips: only create eip of mode elastic_ip 2020-05-28 15:39:06 +08:00
Yousong Zhou
7720380244 networks: create eip network only in default vpc 2020-05-28 15:39:06 +08:00
Yousong Zhou
b62d41a835 apis: network: add NETWORK_TYPE_EIP 2020-05-28 15:39:06 +08:00
Yousong Zhou
a0b39cc7b2 climc: vpcs: add --external-access-mode argument 2020-05-28 15:39:06 +08:00
Yousong Zhou
eebd15e0d5 vpcs: add ExternalAccessMode field 2020-05-28 15:39:06 +08:00
Yousong Zhou
30844db326 apis: add const definitions for eip gateway ips 2020-05-28 15:39:06 +08:00
Yousong Zhou
8d824d2441 Revert "fix: 避免解绑eip后可以立即syncstatus操作导致同步eip出现问题"
This reverts commit 8cc8991372.

Use EipDissociateTask now that it can do lock management for the
associated model
2020-05-28 15:39:06 +08:00
Yousong Zhou
02ea7b4628 tasks: EipDissociateTask: lock associated model 2020-05-28 15:39:06 +08:00
rainzm
cfcaa50e22 feat(notify): Support 'socpe:domain' when list contacts
This is a temporary solution.
2020-05-28 15:27:26 +08:00
Zexi Li
035af9de0e Merge pull request #6640 from ioito/hotfix/qx-openstack-project
fix: typo
2020-05-28 15:26:12 +08:00
Zexi Li
0354a256dc Merge pull request #6641 from ioito/hotfix/qx-typo-fix
fix: typo
2020-05-28 15:26:02 +08:00
Qu Xuan
f9dcb2bb77 fix: typo 2020-05-28 14:38:20 +08:00
Qu Xuan
05012f0bac fix: typo 2020-05-28 14:11:16 +08:00
Zexi Li
568a16e025 Merge pull request #6592 from ioito/hotfix/qx-openstack-project
fix: 通用指定项目到云上创建资源
2020-05-28 13:50:57 +08:00
Qu Xuan
caf07c2561 fix: 避免因磁盘数量导致创建机器失败 2020-05-28 12:06:37 +08:00
zhaoxiangchun
00fb77e0c0 修复优化建议资源列表cloudenv过滤失效的问题 2020-05-27 22:12:38 +08:00
zhaoxiangchun
0a7b381cf6 类型是onecloud的notifier增加webconsole的alert 2020-05-27 22:10:33 +08:00
Qiu Jian
f54d633258 fix: sysadmin cannot convert host in non-default domain 2020-05-27 21:10:59 +08:00
Zexi Li
6c87cd3151 Merge pull request #6621 from wanyaoqi/bugfix/wyq/host-storage-misc-fix
host storage misc fix:
2020-05-27 18:03:47 +08:00
Zexi Li
dfe8700dca Merge pull request #6618 from swordqiu/hotfix/qj-host-convert-baremetal-previleges
fix: domain user no previleges to convert host
2020-05-27 18:02:49 +08:00
Zexi Li
1ec17dd5b0 Merge pull request #6609 from wanyaoqi/bugfix/wyq/fix-host-name-validator
bugfix: fix host name validator
2020-05-27 18:01:09 +08:00
Zexi Li
0d93c985fe Merge pull request #6605 from ioito/hotfix/qx-remove-azure-policy-sync
fix: 移除azure policy sync部分
2020-05-27 17:55:40 +08:00
Zexi Li
fce9d7dac9 Merge pull request #6613 from swordqiu/hotfix/qj-scheduler-test-ignore-quota
fix: scheduler test ignore quota limit
2020-05-27 17:54:39 +08:00
Zexi Li
4b719d229e Merge pull request #6616 from yousong/bugfix/yousong-vet
Bugfix/yousong vet
2020-05-27 17:53:17 +08:00
Zexi Li
a998e505c5 Merge pull request #6619 from ioito/hotfix/qx-azure-detach-disk
fix: 避免azure卸载磁盘失败
2020-05-27 17:51:46 +08:00
wanyaoqi
73297de60c clean network scripts on init 2020-05-27 17:11:32 +08:00
wanyaoqi
690a5f2fca host storage misc fix:
- add accessible timeout
- add force detach host storage
2020-05-27 15:54:37 +08:00
Qu Xuan
d4b16667de fix: 避免azure卸载磁盘失败 2020-05-27 15:54:19 +08:00
Qiu Jian
c563f021b0 fix: domain user no previleges to convert host 2020-05-27 15:46:53 +08:00
Yousong Zhou
e80c938bad .circleci: run with parallel level 3
Resources: 2CPU/4096MB
2020-05-27 15:18:18 +08:00
Yousong Zhou
8e40ff64f5 build: add vet-check 2020-05-27 15:13:50 +08:00
Yousong Zhou
fb26b0c389 vet: composite literal uses unkeyed fields 2020-05-27 15:08:02 +08:00
Zexi Li
d236823a0f Merge pull request #6580 from yousong/bugfix/yousong-k8scidr-default-off
hostman: options: remove k8s_cluster_cidr
2020-05-27 14:37:16 +08:00
Zexi Li
32617b7486 Merge pull request #6607 from yousong/bugfix/yousong-vpcagent
Bugfix/yousong vpcagent
2020-05-27 14:35:52 +08:00
Yousong Zhou
d25f92af8b vet: bad syntax for struct tag value 2020-05-27 14:35:48 +08:00
Yousong Zhou
b99157f646 vet: pairs not separated by spaces 2020-05-27 14:35:48 +08:00
Yousong Zhou
c18d347b0c vet: bad syntax for struct tag pair 2020-05-27 14:35:48 +08:00
Yousong Zhou
85d238cb5a vet: unreachable code 2020-05-27 14:35:48 +08:00
Zexi Li
149bbc3bc1 Merge pull request #6589 from swordqiu/hotfix/qj-baremetal-retry-ipmi-if-redfish-fails
fix: retry ipmi probe if redfish-api-probe fails
2020-05-27 14:35:02 +08:00
Qiu Jian
354a61632d fix: scheduler test ignore quota limit 2020-05-27 10:10:39 +08:00
wanyaoqi
ec2cb3113b fix host name validator 2020-05-26 23:16:41 +08:00
Zexi Li
cb8f5e8864 Merge pull request #6603 from ioito/hotfix/qx-sku-filter
fix: sku status filter
2020-05-26 18:23:46 +08:00
Yousong Zhou
68b7ecf83a hostman: options: remove k8s_cluster_cidr
Remove instead of deprecation.  No user of this option anymore
2020-05-26 17:55:26 +08:00
Qu Xuan
9e07cda2bd fix: 移除azure policy sync部分 2020-05-26 17:55:16 +08:00
Yousong Zhou
cbe5ef4161 hostman: options: fix default value spec 2020-05-26 17:50:41 +08:00
Yousong Zhou
146ab44fbd vpcagent: models: separate Copy() and CopyJoined() 2020-05-26 17:50:41 +08:00
Yousong Zhou
cb27b18052 vpcagent: apihelper: use CopyJoined() 2020-05-26 17:50:41 +08:00
Yousong Zhou
c4b3084896 vpcagent: models: add CopyJoined() 2020-05-26 17:50:41 +08:00
Yousong Zhou
8873c8905e vpcagent: remove unused code 2020-05-26 17:50:41 +08:00
Yousong Zhou
230f004f36 vpcagent: apihelper: use its own options 2020-05-26 17:50:41 +08:00
Zexi Li
3ce96aa193 Merge pull request #6598 from wanyaoqi/bugfix/wyq/fix-remotefile-fetch-image-properties
bugfix: fix remotefile fetch image properties
2020-05-26 17:15:15 +08:00
Zexi Li
28273e56db Merge pull request #6594 from ioito/hotfix/qx-bucket-fix
fix: bucket信息修正
2020-05-26 17:13:43 +08:00
Qu Xuan
95ae69c2ba fix: sku status filter 2020-05-26 17:08:07 +08:00
wanyaoqi
810de8a7ea fix remotefile fetch image propertites 2020-05-26 15:50:19 +08:00
Qu Xuan
f89be60e69 fix: bucket信息修正 2020-05-26 15:05:42 +08:00
Qu Xuan
893d77398b fix: tmp update 2020-05-26 14:31:50 +08:00
Qu Xuan
9916c99172 fix: 通用指定项目到云上创建资源 2020-05-25 20:16:47 +08:00
Zexi Li
c05e24371e Merge pull request #6533 from rainzm/gt/cf_guest
Feat/guest_template
2020-05-25 18:35:27 +08:00
Zexi Li
8e11ec367d Merge pull request #6587 from swordqiu/hotfix/qj-keystone-idp-missing-details
fix: identity_provider details missing fields
2020-05-25 18:34:12 +08:00
Zexi Li
632b482e36 Merge pull request #6548 from wanyaoqi/feature/wyq/isolate-device-add-attribute-reserved-resource
feature: isolated device add attribute reserved resource
2020-05-25 18:33:51 +08:00
Qiu Jian
3699a9b20f fix: retry ipmi probe if redfish-api-probe fails 2020-05-25 17:48:17 +08:00
Qiu Jian
f9bc5f6922 fix: identity_provider details missing fields 2020-05-25 17:33:06 +08:00
wanyaoqi
91ff1d7d84 isolated device add attribute reserved resource 2020-05-25 17:31:34 +08:00
Zexi Li
48fb78f403 Merge pull request #6543 from yousong/bugfix/yousong-vpcagent
vpcagent: models: remove now boilerplate code
2020-05-25 14:32:35 +08:00
Zexi Li
fa3a0b59cc Merge pull request #6572 from swordqiu/hotfix/qj-update-model-api
update for doc-gen
2020-05-25 13:09:02 +08:00
yunion-ci-robot
6d8a4af571 Merge pull request #6578 from zexi/hotfix/baremetal-init-lockman
baremetal: fix forget init lockman pkg
2020-05-25 12:49:55 +08:00
Zexi Li
edf4813fb7 Merge pull request #6573 from zhaoxiangchun/bugfix/zxc-zstack-mon
zstack宿主机监控中增加参数信息进行Unmarshal
2020-05-25 12:17:50 +08:00
Zexi Li
8ebabd6ae3 baremetal: fix forget init lockman pkg 2020-05-25 12:15:21 +08:00
zhaoxiangchun
47cac3c7be zstack宿主机监控中增加参数信息进行Unmarshal 2020-05-24 17:14:40 +08:00
Qiu Jian
8a77030823 update for doc-gen 2020-05-23 13:42:59 +08:00
Zexi Li
b859eea7e6 Merge pull request #6567 from swordqiu/hotfix/qj-default-policy-not-effective
fix: default policy not effective
2020-05-22 22:48:10 +08:00
Zexi Li
8380583934 Merge pull request #6565 from rainzm/notify/contactType
Notify/contact type
2020-05-22 22:47:00 +08:00
Zexi Li
0512de8f2b Merge pull request #6558 from ioito/hotfix/qx-openstack-boot-index
fix: 避免openstack以镜像做系统盘创建失败
2020-05-22 22:45:11 +08:00
Qiu Jian
03477cbe72 fix: default policy not effective 2020-05-22 22:31:14 +08:00
rainzm
f73bcf8ad1 feat: Supports disabling of feishu and dingtalk notification 2020-05-22 20:50:13 +08:00
Qu Xuan
b31922a3b9 fix: 避免openstack以镜像做系统盘创建失败 2020-05-22 20:15:53 +08:00
rainzm
ee85dec1ce fix: Support filtering notification with contactType 2020-05-22 20:06:07 +08:00
Zexi Li
4561da4ea7 Merge pull request #6534 from ioito/hotfix/qx-azure-image
fix: 避免azure uefi重装系统失败
2020-05-22 19:39:00 +08:00
Zexi Li
03fa45da48 Merge pull request #6545 from rainzm/sg/export_keys
fix: Fix problem about exporting fields in scaling group
2020-05-22 19:34:50 +08:00
Zexi Li
7c8ade5e8d Merge pull request #6549 from ioito/hotfix/qx-secgroup-rule-tenant-id
fix: 返回项目信息
2020-05-22 19:33:46 +08:00
Zexi Li
5b8063bc46 Merge pull request #6551 from swordqiu/hotfix/qj-role-empty-match-polciies
fix: empty matched policies list for roles
2020-05-22 19:32:01 +08:00
Qiu Jian
728524fefc fix: empty matched policies list for roles 2020-05-22 18:47:57 +08:00
Qu Xuan
5cdeebb046 fix: 返回项目信息 2020-05-22 17:31:00 +08:00
Qu Xuan
0f2ff53847 fix: 加入Azure套餐和镜像的检查 2020-05-22 16:09:39 +08:00
rainzm
849628fe91 Fix the problem of field duplication when exporting fields 2020-05-22 15:50:54 +08:00
Qu Xuan
a9c0012006 fix: 避免azure uefi重装系统失败 2020-05-22 15:09:38 +08:00
Zexi Li
575f1c2d56 Merge pull request #6540 from ioito/hotfix/qx-azure-image-sync
fix: 避免因io问题导致同步镜像列表为空
2020-05-22 14:43:34 +08:00
rainzm
f9b7c7e571 feat(region): Check periodically whether Guest Template is valid 2020-05-22 13:57:37 +08:00
rainzm
1265e5d1e9 feat: Support vm to save server template 2020-05-22 13:57:25 +08:00
Qu Xuan
a7e1bdf6f5 fix: 避免因io问题导致同步镜像列表为空 2020-05-22 13:46:13 +08:00
Zexi Li
1e85456200 Merge pull request #6530 from ioito/hotfix/qx-rds-backup-create
fix: aliyun rds backup create fix
2020-05-22 12:37:58 +08:00
Yousong Zhou
3e09d4920b vpcagent: models: remove now boilerplate code 2020-05-22 11:10:11 +08:00
Yousong Zhou
c7fee7c760 vpcagent: apihelper: add interface IModelSetListOptionProvider
All modelsets do not need details at the moment
2020-05-22 11:10:11 +08:00
Zexi Li
5413d3c98f Merge pull request #6527 from rainzm/notify/email_verify
feat(notify): Change the format of verify email
2020-05-22 10:26:32 +08:00
Zexi Li
947d510951 Merge pull request #6531 from ioito/hotfix/qx-gcp-bucket-acl
fix: gcp bucket文件夹默认设为private
2020-05-22 10:25:55 +08:00
Zexi Li
5225aced10 Merge pull request #6525 from tb365/bugfix/tb-bugfix-0521
aws lbbg cache bugfix
2020-05-22 10:24:30 +08:00
Zexi Li
7a0a2fadfd Merge pull request #6511 from ioito/hotfix/qx-secgroup-sync
fix: 避免忽略本地allow any云上deny any安全组规则同步
2020-05-22 10:22:19 +08:00
Zexi Li
701c2bfc4c Merge pull request #6504 from yousong/bugfix/yousong-vpcagent
vpcagent: apihelper: 去除details=true查询
2020-05-22 10:21:47 +08:00
Zexi Li
a076aae248 Merge pull request #6509 from wanyaoqi/bugfix/wyq/fix-list-disk-attachable-servers
bugfix: fix list disk attachable servers
2020-05-22 10:20:17 +08:00
Zexi Li
815ef99319 Merge pull request #6535 from swordqiu/hotfix/qj-schedtag-usage
fix: usage for schetag not accurate
2020-05-22 10:19:15 +08:00
Zexi Li
ae51b32f59 Merge pull request #6528 from ioito/hotfix/qx-network-list-filter
fix: 避免regional network-list --zone导致返回结果为空
2020-05-22 10:17:55 +08:00
Zexi Li
cbd2355efc Merge pull request #6516 from swordqiu/hotfix/qj-login-without-system-privileges
fix: system privileges user cannot access system console
2020-05-22 10:15:07 +08:00
yunion-ci-robot
5612e6cf90 Merge pull request #6505 from ioito/hotfix/qx-image-upload
fix: 上传镜像为转换列表之外时,subformat状态异常
2020-05-21 23:03:50 +08:00
Qiu Jian
1dfef4dcfa fix: usage for schetag not accurate 2020-05-21 22:35:38 +08:00
Qu Xuan
ef25bf3282 fix: gcp bucket文件夹默认设为private 2020-05-21 20:53:05 +08:00
Qu Xuan
b260c04c39 fix: aliyun rds backup create fix 2020-05-21 20:36:09 +08:00
Qu Xuan
8bc4927d57 fix: 避免regional network-list --zone导致返回结果为空 2020-05-21 20:14:25 +08:00
rainzm
c706cfa272 feat(notify): Change the format of verify email 2020-05-21 19:12:52 +08:00
tangbin
d99ec57710 aws lbbg cache bugfix 2020-05-21 18:52:23 +08:00
Qiu Jian
29283ff118 fix: system privileges user cannot access system console 2020-05-21 18:36:42 +08:00
Qu Xuan
c8ba52c94a fix: 避免忽略本地allow any云上deny any安全组规则同步 2020-05-21 18:28:43 +08:00
wanyaoqi
df2e05b5b6 fix list disk attachable servers 2020-05-21 17:56:18 +08:00
Qu Xuan
1354270c51 fix: 上传镜像为转换列表之外时,subformat状态异常 2020-05-21 17:40:27 +08:00
Yousong Zhou
f5360264fe vpcagent: models: modelset: details=false for networks 2020-05-21 17:21:03 +08:00
Yousong Zhou
3a51985fcd vpcagent: models: include wires 2020-05-21 17:21:03 +08:00
Yousong Zhou
5fdd534f74 vpcagent: ovn: preparation: skip default vpc 2020-05-21 17:21:03 +08:00
Yousong Zhou
a7a3beae27 vpcagent: ovn: preparation: use network.Vpc.Id 2020-05-21 17:21:03 +08:00
Yousong Zhou
e0349f92b7 vpcagent: apihelper: use IModelSet.IncludeEmulated() 2020-05-21 17:21:03 +08:00
Yousong Zhou
5bf45ad65c vpcagent: models: modelset: add IncludeEmulated() method 2020-05-21 17:21:03 +08:00
Yousong Zhou
39a19d1c68 vpcagent: apihelper: use IModelSet.IncludeDetails() 2020-05-21 17:21:03 +08:00
Yousong Zhou
2a0cac9d49 vpcagent: models: modelset: add IncludeDetails() method 2020-05-21 17:21:03 +08:00
Yousong Zhou
9a47116a1d mcclient: options: remove implied details=true for pending_delete=all 2020-05-21 17:21:03 +08:00
Zexi Li
daf9db81dd Merge pull request #6499 from swordqiu/hotfix/qj-init-cloud-account-share-mode
fix: cloudaccount share_mode not initialized
2020-05-21 17:04:29 +08:00
Zexi Li
9b37c107c0 Merge pull request #6500 from zhaoxiangchun/bugfix/zxc-monitor-notify
Fix the problem that notify cannot be triggered when prestate = alerting and newstate = alerting
2020-05-21 16:37:48 +08:00
Zexi Li
b2f0e48b23 Merge pull request #6472 from zhaoxiangchun/bugfix/zxc-suggest-mon
suggestions  increase time screening range
2020-05-21 16:34:05 +08:00
Zexi Li
bd324238d2 Merge pull request #6487 from rainzm/fix/esxi
Fix/esxi
2020-05-21 16:32:46 +08:00
Zexi Li
b5ed7f8d74 Merge pull request #6497 from wanyaoqi/bugfix/wyq/storage-cache-image-use-lockman
bugfix: image cache use lockman
2020-05-21 16:31:40 +08:00
yunion-ci-robot
012631bb46 Merge pull request #6503 from rainzm/ansible/requirement
fix: 'requirements' in ansibleplaybookv2 should be optional
2020-05-21 15:22:43 +08:00
zhaoxiangchun
c8a0d77364 bugfix-优化建议
在删除资源列表的信息时,增加对应的状态值。如果删除失败记录相关日志
2020-05-21 15:16:45 +08:00
zhaoxiangchun
42ed0b1c5a 优化建议增加时间筛选范围
1.在时间范围内查询未使用的资源,对于存在解绑的操作,通过查询对应的日志来确定最近的使用时间
2.基于监控的优化建议,增加新的reducer,当有足够多的points时,再进行其他逻辑
2020-05-21 15:16:45 +08:00
rainzm
77e5801ad9 fix: 'requirements' in ansibleplaybookv2 should be optional 2020-05-21 14:20:48 +08:00
zhaoxiangchun
4a784c1d7f 修复当prestate=alerting,newstate=alerting的情况无法触发notify的问题 2020-05-21 13:06:22 +08:00
Qiu Jian
08eda0d44d fix: cloudaccount share_mode not initialized 2020-05-21 11:55:26 +08:00
rainzm
d710248496 fix(esxi): Modify the disk size correctly when creating vm 2020-05-21 10:49:21 +08:00
rainzm
9bb7320771 fix(esxi): Detach all disk first when deleting vm 2020-05-21 10:45:55 +08:00
rainzm
ff2fc74401 Kill processes in time & Add debug info 2020-05-21 10:45:43 +08:00
wanyaoqi
127bd0ff17 image cache use lockman 2020-05-21 10:42:32 +08:00
Zexi Li
899c31d8b4 Merge pull request #6485 from wanyaoqi/feature/wyq/add-guest-sys-usage
guest add sys usage
2020-05-21 10:02:23 +08:00
Zexi Li
0843439dba Merge pull request #6494 from yousong/bugfix/yousong-server-list-nics
guests: include vpc, network info in guest nics list
2020-05-21 10:00:19 +08:00
Yousong Zhou
b29c4b3869 guests: include vpc, network info in guest nics list 2020-05-20 22:45:16 +08:00
Zexi Li
4e64f38851 Merge pull request #6491 from zexi/hotfix/keystone-db-sync
keystone: fix db not sync
2020-05-20 17:32:10 +08:00
Zexi Li
9a6065fbf2 keystone: fix db not sync 2020-05-20 17:20:51 +08:00
rainzm
dae02ec019 fix(esxi): Remove 'Destory' operation that is unnecessary for VirtualDiskManager 2020-05-20 15:36:25 +08:00
rainzm
b6ce495d4f fix(esxi): Separate detach disk and delete disk when rebuilding.
In previous versions, set
`removeSpec.FileOperation = types.VirtualDeviceConfigSpecFileOperationDestroy'
to delete disk indirectly.

But, when its parent has only one child, the parent will be deleted along with it.
And the consequence is failure to reinstall the system.

Now, detach disk without deleteing backing file and then remove backing
2020-05-20 15:33:13 +08:00
wanyaoqi
844b865e2e add sys usage 2020-05-20 14:01:58 +08:00
Zexi Li
cd317817da Merge pull request #6481 from zexi/hotfix/region-resource-details-panic
region: fix get resource details panic
2020-05-20 14:00:05 +08:00
Zexi Li
0b70491ea0 region: fix get resource details panic 2020-05-20 13:26:10 +08:00
Zexi Li
d8d4c6f24e Merge pull request #6479 from yousong/bugfix/yousong-travis-badge
README.md: use travis-ci.com as badge target link
2020-05-20 12:54:04 +08:00
Zexi Li
b8871a4b22 Merge pull request #6474 from yousong/bugfix/yousong-region
Bugfix/yousong region
2020-05-20 12:52:59 +08:00
Zexi Li
e4e91ade65 Merge pull request #6473 from ioito/hotfix/qx-azure-resource-group
Hotfix/qx azure resource group
2020-05-20 12:52:42 +08:00
Yousong Zhou
ea373821d2 README.md: use travis-ci.com as badge target link 2020-05-20 11:55:58 +08:00
Zexi Li
a76427c3ae Merge pull request #6456 from swordqiu/hotfix/qj-cloud-provider-list-usable-filter
fix: cloudprovider list support filter by zone and cloudregion
2020-05-20 11:09:00 +08:00
Zexi Li
25a6da393d Merge pull request #6453 from ioito/hotfix/qx-azure-image-sync-optimized
fix: 优化azure image同步逻辑
2020-05-20 11:08:16 +08:00
Zexi Li
e445b22a44 Merge pull request #6434 from ioito/hotfix/qx-vhd-check
fix: 加入azure镜像vhd检查
2020-05-20 11:07:37 +08:00
Zexi Li
d4a9588335 Merge pull request #6427 from ioito/hotfix/qx-secgroup-sync-optimized
fix: 避免大范围安全组共享
2020-05-20 11:07:13 +08:00
yunion-ci-robot
adbaf6b6af Merge pull request #6461 from tb365/feature/tb-condition-release
redis&dbinstance add clean expired postpaids resources
2020-05-20 11:01:42 +08:00
Yousong Zhou
72c23e8776 networks: return HTTP 404 for sql.ErrNoRows 2020-05-20 11:00:36 +08:00
Yousong Zhou
d83a7dade5 wires: default to "default" vpc on creation
Wire creation request right now only makes sense in context of classic
network ("default" vpc)
2020-05-20 11:00:36 +08:00
Yousong Zhou
1d78510fab networks: eliminate a variable 2020-05-20 11:00:36 +08:00
Yousong Zhou
df2d98d8c2 guestdrivers: managed: use const api.EIP_STATUS_ASSOCIATE 2020-05-20 11:00:36 +08:00
Yousong Zhou
ef695acae0 cloudprovider: fix typo 2020-05-20 11:00:36 +08:00
Yousong Zhou
5499f35090 cloudcommon: rbac: fix typo 2020-05-20 11:00:36 +08:00
Zexi Li
0f9f4ec381 Merge pull request #6468 from zexi/hotfix/host-convert-docker-config
host convert inject dockerd config
2020-05-20 10:44:26 +08:00
Qu Xuan
f9b1466f44 fix: 支持公有云指定资源组 2020-05-20 10:26:32 +08:00
tangbin
0029b25f9a redis&dbinstance add clean expired postpaids resources 2020-05-19 19:42:14 +08:00
Qu Xuan
4b5f8b8d5c fix: 支持指定resource group 2020-05-19 19:33:29 +08:00
Zexi Li
9aff012b28 Merge pull request #6463 from tb365/bugfix/tb-network-ip-query-fix
add fuzzy ip matching
2020-05-19 19:15:23 +08:00
Zexi Li
6a907ec9e4 Merge pull request #6458 from ioito/hotfix/qx-zstack-windows-user-data
fix: 修复zstack使用win镜像时userdata base64加密问题
2020-05-19 19:13:41 +08:00
Zexi Li
fed036c209 Merge pull request #6462 from zexi/hotfix/server-create-params
region: fix server create params not include specified resource
2020-05-19 19:08:30 +08:00
Zexi Li
04b4e5713e host convert inject dockerd config 2020-05-19 19:07:44 +08:00
tangbin
f602979a23 add fuzzy ip matching 2020-05-19 17:39:13 +08:00
Zexi Li
4713312b32 region: fix server create params not include specified resource 2020-05-19 17:22:26 +08:00
Qu Xuan
f162ac46fe fix: 修复zstack使用win镜像时userdata base64加密问题 2020-05-19 16:45:32 +08:00
Qiu Jian
50f55c299c fix: cloudprovider list support filter by zone and cloudregion 2020-05-19 16:42:25 +08:00
Qu Xuan
b18035442e fix: 优化azure image同步逻辑 2020-05-19 16:23:37 +08:00
Zexi Li
d4217ff151 Merge pull request #6450 from zexi/feature/k8s-helm-cli
climc: update k8s resource cmd
2020-05-19 15:49:30 +08:00
Zexi Li
2a06b9f24c Merge pull request #6451 from swordqiu/hotfix/qj-ini-policy-create-fail
fix: policy create fail on initialization phrase
2020-05-19 15:48:17 +08:00
Zexi Li
9f0df58c95 climc: update k8s resource cmd 2020-05-19 15:26:02 +08:00
Qiu Jian
5b60c4fad8 fix: policy create fail on initialization phrase 2020-05-19 15:08:44 +08:00
Zexi Li
1bb2ef919c Merge pull request #6421 from ioito/hotfix/qx-metdata-list-optimized
fix: 优化标签列表过滤参数
2020-05-19 10:21:31 +08:00
Zexi Li
aa3cd307ba Merge pull request #6441 from swordqiu/hotfix/qj-fix-local-storage-ownership-sync
Hotfix/qj fix local storage ownership sync
2020-05-19 10:19:05 +08:00
Zexi Li
afa46799a1 Merge pull request #6443 from swordqiu/hotfix/qj-anonymous-user-may-list-resources
fix: anonymous user may list resources
2020-05-19 10:17:47 +08:00
Zexi Li
09381fdd73 Merge pull request #6436 from zexi/hotfix/baremetal-deploy-disable-cloud-init
baremetal: fix ssh put empty content file not created
2020-05-19 10:15:59 +08:00
Qiu Jian
f4a676575a fix: anonymous user may list resources 2020-05-19 01:13:00 +08:00
Qiu Jian
14abf05cf4 sync storage shared info when syncing local storage 2020-05-18 23:19:32 +08:00
Qiu Jian
6037f15145 update lisDescendent scope params 2020-05-18 21:58:24 +08:00
Qu Xuan
8f4e0a5e84 fix: 避免大范围安全组共享 2020-05-18 21:54:10 +08:00
Zexi Li
38c956bd10 Merge pull request #6418 from ioito/hotfix/qx-list-filter
Hotfix/qx list filter
2020-05-18 21:51:07 +08:00
Zexi Li
45ec40cac7 Merge pull request #6423 from ioito/hotfix/qx-cloudprovider-sync
fix: 避免仅同步一个region时,其余region状态变为准备中
2020-05-18 21:49:04 +08:00
Zexi Li
95ffe11c02 Merge pull request #6428 from ioito/hotfix/qx-guest-expired-time
fix: 避免设置自动释放后磁盘的expired_at失效
2020-05-18 21:47:40 +08:00
Zexi Li
ef9de2e4c1 Merge pull request #6432 from swordqiu/hotfix/qj-fix-permission-tags
fix: update fields permission tags
2020-05-18 21:47:12 +08:00
Zexi Li
541c72849a baremetal: fix ssh put empty content file not created 2020-05-18 21:43:36 +08:00
Qu Xuan
f9c794f745 fix: image-list --sub-format support 2020-05-18 21:20:33 +08:00
Qu Xuan
589a4678fa fix: 加入azure镜像vhd检查 2020-05-18 21:04:38 +08:00
Qiu Jian
d1fd245384 fix: update fields permission tags 2020-05-18 20:58:33 +08:00
Qu Xuan
3fe417c4f6 fix: 避免设置自动释放后磁盘的expired_at失效 2020-05-18 20:00:19 +08:00
Qu Xuan
33c2b5fa9d fix: 避免仅同步一个region时,其余region状态变为准备中 2020-05-18 19:36:46 +08:00
Qu Xuan
e306a4e23f fix: 优化标签列表过滤参数 2020-05-18 15:29:45 +08:00
Qu Xuan
888a5463ab 根据调度标签过滤网络和存储资源 2020-05-18 12:03:10 +08:00
Qu Xuan
6ea25e6fcc 可根据代理过滤云账号 2020-05-18 11:26:20 +08:00
Zexi Li
bbeb6be583 Merge pull request #6401 from swordqiu/hotfix/qj-permission-for-disabled-policy
fix: fail to explain permission for disabled policy
2020-05-17 14:22:15 +08:00
Zexi Li
ac67b19ae4 Merge pull request #6417 from swordqiu/feature/qj-billing-latest-last-start
feature: add functime get lastest last start time of a billing duration
2020-05-17 14:20:24 +08:00
Zexi Li
b3ca71e613 Merge pull request #6410 from zhaoxiangchun/bugfix/zxc-esxi-host-mon
Repair failed to get VMware host monitoring data
2020-05-17 14:16:38 +08:00
Zexi Li
d3cb3930a8 Merge pull request #6402 from swordqiu/hotfix/qj-disable-delete-standard-image
fix: disable delete standard image
2020-05-17 14:15:11 +08:00
Qiu Jian
81b6a766a9 feature: add functime get lastest last start time of a billing duration 2020-05-16 22:32:51 +08:00
yunion-ci-robot
03ee9901c9 Merge pull request #6408 from rainzm/vendor/update
update vendor for master
2020-05-16 22:07:08 +08:00
zhaoxiangchun
6ffb3653ae 修复无法获取vmware宿主机监控数据的问题 2020-05-16 21:15:52 +08:00
rainzm
d98b2b4053 update vendor 2020-05-16 21:02:15 +08:00
Zexi Li
d8560a0de5 Merge pull request #6394 from swordqiu/hotfix/qj-scope-system-for-agents
fix: xxx-agent should generally use scope=system to list resources
2020-05-16 17:45:42 +08:00
Zexi Li
42a55ce9b2 Merge pull request #6395 from swordqiu/hotfix/qj-server-sync-fix-nics
fix: server-sync-fix-nics should return errors if vnics ip is not reachable on host
2020-05-16 17:44:19 +08:00
Zexi Li
b3c1b1eca5 Merge pull request #6375 from rainzm/fix/isinit
Fix/esxi
2020-05-16 17:41:24 +08:00
yunion-ci-robot
f91f381b8c Merge pull request #6388 from zexi/hotfix/baremetal-enable-public-netif
region: fix baremetal can't enable public baremetal type network
2020-05-16 17:31:07 +08:00
Qiu Jian
b312b5dacb fix: bugfixes 2020-05-16 01:04:12 +08:00
Qiu Jian
ed5463ca68 fix: disable delete standard image 2020-05-16 00:34:54 +08:00
Qiu Jian
54689d862b fix: fail to explain permission for disabled policy 2020-05-16 00:18:28 +08:00
Qiu Jian
605978a94e fix: server-sync-fix-nics should return errors if vnics ip is not
reachable on host
2020-05-15 22:14:20 +08:00
Qiu Jian
41125788fe fix: xxx-agent should generally use scope=system to list resources 2020-05-15 22:09:41 +08:00
rainzm
60a363a79a fix(esxi): Allow the creation of duplicate vcenter machines.
Create vm with name whose vlaue is localVM.Uuid and try to rename again.
2020-05-15 21:29:10 +08:00
rainzm
874ea4eb4a fix(esxi): Add usb to support mouse in vnc viewer 2020-05-15 20:58:39 +08:00
rainzm
81ffd582f6 fix(esxi): Fix GetDriver and add driver log for vdisk.
In GetDriver, return 'name' directly if driverMap is empty.
2020-05-15 20:38:45 +08:00
rainzm
33184357bf fix(esxi): Set 'WindowsDefaultAdminUser' as true when deploy vm.
'WindowsDefaultAdminUser' means that the default admin account is
'Administrator' when deploy windows vm.
2020-05-15 20:34:00 +08:00
rainzm
45305648d4 fix(region): Set default value if rootdisk's driver is empty. 2020-05-15 20:31:36 +08:00
rainzm
3530bca49f fix(esxi): Disable automatically add host to the dvs 2020-05-15 20:22:51 +08:00
Zexi Li
fe055916c3 Merge pull request #6386 from yousong/bugfix/yousong-vpcagent
Bugfix/yousong vpcagent
2020-05-15 19:59:15 +08:00
Zexi Li
80a405a8a0 region: fix baremetal can't enable public baremetal type network 2020-05-15 19:56:53 +08:00
Yousong Zhou
4d54972a9a vpcagent: ovnutil: destroy non root obj first
To avoid the following error

	/* Can't happen because of the database schema. */
	ctl_fatal("logical port %s is not part of any logical router",
		  ctx->argv[1]);
2020-05-15 16:28:17 +08:00
Yousong Zhou
6d788e052a vpcagent: ovn: cmp: generate clean args in a single batch 2020-05-15 16:28:17 +08:00
Zexi Li
66168cb8c5 Merge pull request #6379 from ioito/bugfix/qx-rds-backup-list
fix: 避免backup list未能正常显示rds信息
2020-05-15 15:29:32 +08:00
Zexi Li
cd17057364 Merge pull request #6381 from zexi/hotfix/scheduler-min-conters
scheduler: fix min counter get count not correct
2020-05-15 15:27:57 +08:00
Zexi Li
db65bf4ef0 scheduler: fix min counter get count not correct 2020-05-15 15:04:38 +08:00
Qu Xuan
d82cf4184b fix: 避免backup list未能正常显示rds信息 2020-05-15 14:29:14 +08:00
rainzm
2fe738b468 fix(esxi): Set 'IsInit' as true when rebuildroot
IsInit is true will cause cloudinit enable. When rebuilding root, if there is cloudinit service in the image, it will cover the initialization work we did on the rebuilding.
2020-05-15 11:15:39 +08:00
Zexi Li
aa254f927b Merge pull request #6346 from ioito/hotfix/qx-cloud-init
fix: 优化windows powershell userdata
2020-05-15 11:09:40 +08:00
Zexi Li
43fc7be0c0 Merge pull request #6363 from swordqiu/hotfix/qj-image-upload-public-scope
fix: set public_scope to system for image with is_public=true
2020-05-15 11:08:12 +08:00
Zexi Li
e73fb2cc31 Merge pull request #6352 from ioito/hotfix/qx-rds-sync-optimized
fix: 优化rds zone同步逻辑
2020-05-15 11:05:42 +08:00
Zexi Li
84fe0085a4 Merge pull request #6358 from zhaoxiangchun/bugfix/zxc-suggest-mon
modify the logic of queryCondition save the  evalMatch
2020-05-15 11:04:45 +08:00
zhaoxiangchun
387880164c modify the logic of queryCondition save the evalMatch 2020-05-15 10:11:16 +08:00
Qiu Jian
eb54f316c7 fix: set public_scope to system for image with is_public=true 2020-05-15 00:30:03 +08:00
Qu Xuan
fc4778f332 fix: 优化rds zone同步逻辑 2020-05-14 19:43:38 +08:00
Zexi Li
86fbbf5a65 Merge pull request #6353 from zexi/hotfix/scheduler-schedtag-empty-strategy
scheduler: filter disabled cloudprovider
2020-05-14 18:58:36 +08:00
Zexi Li
0d2ec73865 Merge pull request #6344 from tb365/bugfix/tb-bugfix-0514
allow delete paramter config
2020-05-14 18:20:41 +08:00
Zexi Li
3d74264385 Merge pull request #6338 from swordqiu/hotfix/qj-aoid-use-background-context
fix: avoid using background context
2020-05-14 18:18:21 +08:00
Zexi Li
31110901d2 Merge pull request #6336 from zhaoxiangchun/bugfix/zxc-suggest-mon
Modify the logic of rule change execution time
2020-05-14 18:17:45 +08:00
Zexi Li
2e93072691 scheduler: filter disabled cloudprovider 2020-05-14 18:09:26 +08:00
Zexi Li
811cdedc89 Merge pull request #6347 from zexi/hotfix/scheduler-schedtag-empty-strategy
scheduler: set schedtag default strategy if input empty
2020-05-14 17:49:00 +08:00
Zexi Li
e00b1fdc3b scheduler: set schedtag default strategy if input empty 2020-05-14 17:23:02 +08:00
Qu Xuan
5c6b016c2d fix: 优化windows powershell userdata 2020-05-14 16:48:30 +08:00
Qiu Jian
c35758dd08 fix: avoid using background context 2020-05-14 16:15:54 +08:00
tangbin
cbe5e88907 allow delete paramter config 2020-05-14 15:17:29 +08:00
zhaoxiangchun
e8a61b0352 修改规则执行时间
在将资源数据取到后更新执行时间
2020-05-14 14:57:21 +08:00
Zexi Li
893df7ba2b Merge pull request #6331 from tb365/bugfix/tb-bugfix-0514
clear yunionauth cookie
2020-05-14 13:02:11 +08:00
Zexi Li
17bb2398c5 Merge pull request #6333 from wanyaoqi/bugfix/wyq/rm-statefile-in-start-script
bugfix: remove statefile in start script
2020-05-14 13:01:34 +08:00
wanyaoqi
a5d2651fbf fix esxi disk disconnect 2020-05-14 12:27:41 +08:00
wanyaoqi
0fe396d5c1 remove statefile in start script 2020-05-14 12:07:21 +08:00
tangbin
75328cf081 clear yunionauth cookie 2020-05-14 11:34:02 +08:00
Zexi Li
4e75083306 Merge pull request #6140 from yousong/feature/yousong-vpc-secrules
Feature/yousong vpc secrules
2020-05-14 10:35:11 +08:00
Zexi Li
b2911d4bcd Merge pull request #6328 from swordqiu/hotfix/qj-status-resource-action-log-no-owner
fix: status-base resource's action log missing owner project/domain
2020-05-14 09:53:14 +08:00
Qiu Jian
9c26c04083 fix: status-base resource's action log missing owner project/domain 2020-05-14 01:14:40 +08:00
yunion-ci-robot
19ba882349 Merge pull request #6326 from zexi/hotfix/server-create-prefer-use-name
region: server create prefer resource fetch by name or id
2020-05-14 01:05:30 +08:00
Zexi Li
536be2ead7 region: server create prefer resource fetch by name or id 2020-05-14 00:40:20 +08:00
Zexi Li
246fe02a50 Merge pull request #6164 from zhaoxiangchun/bugfix/zxc-suggest-mon
bugfix-suggestrule cannot disable
2020-05-13 23:01:07 +08:00
Zexi Li
18e931424a Merge pull request #6087 from zhaoxiangchun/feature/zxc-influxdb-schema
在monitor的新增influxdb相关的功能
2020-05-13 22:59:41 +08:00
zhaoxiangchun
cc3f5ed196 基于监控数据的优化建议 2020-05-13 22:24:13 +08:00
zhaoxiangchun
6251d2da3f 在monitor的package中新增influxdb相关的功能
1.可以获取influxdb实例中的databases
2.可以获取指定database中的measurements
3.通过指定measurement获取其中的tags和fileds
2020-05-13 22:24:13 +08:00
Zexi Li
3f3089361c Merge pull request #6324 from swordqiu/hotfix/qj-hide-host-agent-menu
fix: host agent list use baremetalagents model
2020-05-13 21:20:53 +08:00
Qiu Jian
5c8081b6bf fix: host agent list use baremetalagents model 2020-05-13 21:04:44 +08:00
yunion-ci-robot
524a11cda8 Merge pull request #6319 from wanyaoqi/bugfix/wyq/do-close-worker-chan
bugfix: do not close appsrv worker chan
2020-05-13 20:16:03 +08:00
wanyaoqi
7bcedd41e8 do not close worker chan
don't close worker chan after put work, will cause dead loop
2020-05-13 18:55:16 +08:00
Yousong Zhou
4962bdc7e1 vpcagent: ovn: use db.FindOneMatchByAnyIndex 2020-05-13 14:14:49 +08:00
Yousong Zhou
4f68026b84 vendor: update yunion.io/x/ovsdb 2020-05-13 14:14:49 +08:00
Yousong Zhou
579641a268 vpcagent: ovn: configure acl for lport 2020-05-13 14:14:49 +08:00
Yousong Zhou
53f3546125 vpcagent: ovnutil: OvnNbctlArgsDestroy: take into account ACL 2020-05-13 14:14:48 +08:00
Yousong Zhou
9f4daafee2 vpcagent: ovn: secgrouprules_acl 2020-05-13 14:14:48 +08:00
Yousong Zhou
1abdb4f136 vpcagent: models: sort security group rules 2020-05-13 14:14:48 +08:00
Yousong Zhou
7ba46e9289 vpcagent: models: include secgroup and rules 2020-05-13 14:14:48 +08:00
Yousong Zhou
f33a2e1770 vpcagent: apihelper: do not set details=true by default 2020-05-13 14:14:48 +08:00
Yousong Zhou
e8cbaee904 region: guests: include secgroup ids in listing 2020-05-13 14:14:48 +08:00
Yousong Zhou
654845fd49 vpcagent: ovnutil: remove old generated code 2020-05-13 14:14:48 +08:00
Yousong Zhou
cae9594da9 vpcagent: ovn: use yunion.io/x/ovsdb 2020-05-13 14:14:48 +08:00
Yousong Zhou
7c3d9d7f89 vendor: import yunion.io/x/ovsdb 2020-05-13 14:14:48 +08:00
Yousong Zhou
ffadb30c63 vendor: tidy and vendoring 2020-05-13 14:14:48 +08:00
Zexi Li
93a8f42f14 Merge pull request #6305 from swordqiu/hotfix/qj-cascade-change-owner-candidate-domain-list
fix: change-owner-candidate-domains not implemented for some resources
2020-05-13 12:46:07 +08:00
Zexi Li
38d86388aa Merge pull request #6302 from yousong/bugfix/yousong-vpcagent
vpcagent: ignore possible external subnets
2020-05-13 12:45:06 +08:00
Zexi Li
59837952e1 Merge pull request #6297 from ioito/hotfix/qx-cloudprovider-list-filter
fix: cloud-provider-list support filter by cloudregion
2020-05-13 12:43:52 +08:00
Zexi Li
7992804e47 Merge pull request #6241 from swordqiu/feature/qj-auto-login-highest-scope
feature: user login into project with highest privilege automatically
2020-05-13 12:43:20 +08:00
Zexi Li
e14a005d00 Merge pull request #6300 from ioito/bugfix/qx-manager-custom-field
fix: 避免provider错乱返回
2020-05-13 12:43:04 +08:00
Zexi Li
980e9adc18 Merge pull request #6306 from ioito/hotfix/qx-openstack-secgroup
fix: openstack 安全组规则同步
2020-05-13 12:41:26 +08:00
Zexi Li
ff10ff3769 Merge pull request #6315 from ioito/hotfix/qx-reservedips-release
fix: i-ps -> ips
2020-05-13 10:44:45 +08:00
Zexi Li
8bb53e6903 Merge pull request #6317 from swordqiu/hotfix/qj-reserved-ip-owner-filter
fix: reserved ip owner filter
2020-05-13 10:44:07 +08:00
Zexi Li
68e26f31cb Merge pull request #6292 from ioito/bugfix/qx-openstack-err
fix: 优化openstack错误处理
2020-05-13 10:42:28 +08:00
Qiu Jian
07766b7b44 fix: reserved ip owner filter 2020-05-12 21:10:56 +08:00
Qu Xuan
b0b45c4209 fix: i-ps -> ips 2020-05-12 20:26:16 +08:00
Yousong Zhou
218df2416c vpcagent: ignore possible external subnets 2020-05-12 18:05:48 +08:00
Qu Xuan
df5f5c9b9e fix: openstack 安全组规则同步 2020-05-12 17:52:33 +08:00
Qiu Jian
4a84beee0f fix: change-owner-candidate-domains not implemented for some resources 2020-05-12 17:29:52 +08:00
Qu Xuan
bd21b346a5 fix: 避免provider错乱返回 2020-05-12 17:02:08 +08:00
Zexi Li
600226fc2e Merge pull request #6280 from yousong/bugfix/yousong-elect
cloudcommon: elect: notifyOne on subscribe
2020-05-12 14:22:27 +08:00
Zexi Li
bc1c7d60bd Merge pull request #6277 from ioito/hotfix/service-metadata
fix: 支持访问其他服务的标签列表
2020-05-12 14:21:24 +08:00
Qu Xuan
2da49eb0dd fix: 优化openstack错误处理 2020-05-12 14:08:40 +08:00
Qu Xuan
d271ff69f0 fix: cloud-provider-list support filter by cloudregion 2020-05-12 14:05:25 +08:00
Zexi Li
c275e20894 Merge pull request #6224 from wanyaoqi/feature/wyq/guest-set-user
feature: guest set login account
2020-05-12 12:18:36 +08:00
Zexi Li
1ea74e089c Merge pull request #6287 from yousong/bugfix/yousong-lb-undeploy
region: lbagent: undeploy: make it idempotent
2020-05-12 11:49:54 +08:00
Zexi Li
fe7bf4b725 Merge pull request #6282 from yousong/bugfix/yousong-lb
region: lbagents: fix deleting pending_deleted objects
2020-05-12 11:43:30 +08:00
Yousong Zhou
f226d342e1 region: lbagent: undeploy: make it idempotent
Both the following three can result in the same error message "Could not
find the requested service yunion-xx: host"

  -m systemd -a 'name=yunion-xx enabled=no state=stopped daemon_reload=yes'
  -m systemd -a 'name=yunion-xx enabled=no state=stopped daemon_reload=yes force=yes'
  -m service -a 'name=yunion-xx enabled=no state=stopped'

Use of ansibleplaybookv2 is overkill and can break console expectation.
Just turn to shell module for now
2020-05-12 10:38:33 +08:00
Yousong Zhou
f890b2b180 region: lbagents: fix deleting pending_deleted objects
This was broken since the introduction of virtual object
2020-05-12 10:05:56 +08:00
Yousong Zhou
d845700cac cloudcommon: elect: notifyOne on subscribe 2020-05-11 23:26:58 +08:00
Qu Xuan
f01bed833d fix: 支持访问其他服务的标签列表 2020-05-11 21:39:32 +08:00
Zexi Li
51556009fa Merge pull request #6263 from ioito/hotfix/qx-vpc-count
fix: globalvpc count vpc
2020-05-11 21:09:29 +08:00
Zexi Li
53fce79ada Merge pull request #6265 from ioito/hotfix/qx-disk-detach
fix: 避免卸载完已删除的磁盘后,磁盘状态为ready
2020-05-11 21:09:04 +08:00
Zexi Li
e5363a2cbf Merge pull request #6270 from zexi/hotfix/scheduler-region-panic
scheduler: get region nil panic
2020-05-11 21:07:33 +08:00
Zexi Li
1603cfb2a6 Merge pull request #6275 from swordqiu/hotfix/qj-gpu-domain-filter
fix: isolated_devices domain filter not working
2020-05-11 21:06:59 +08:00
Qiu Jian
e9101ebc2e fix: isolated_devices domain filter not working 2020-05-11 20:45:14 +08:00
Zexi Li
8c3dc06cd0 Merge pull request #6257 from swordqiu/hotfix/qj-cloud-account-disabled
fix: create cloudaccount with disabled state
2020-05-11 18:18:46 +08:00
Zexi Li
3a5f3d0a4b Merge pull request #6268 from ioito/hotfix/qx-gcp-rds
fix: gcp rds 默认不使用vpc网络
2020-05-11 18:18:03 +08:00
Zexi Li
7f08417597 Merge pull request #6258 from ioito/hotfix/qx-disk-billing-type
fix: 避免aliyun磁盘计费类型多次转换
2020-05-11 18:16:43 +08:00
Qiu Jian
108613bd32 detect bmagent and hostagent service 2020-05-11 17:25:43 +08:00
Qu Xuan
8cfbf9a8fe fix: gcp rds 默认不使用vpc网络 2020-05-11 14:52:02 +08:00
Zexi Li
d049ac936e scheduler: get region nil panic 2020-05-11 14:40:21 +08:00
Qu Xuan
8a8d0f9005 fix: 避免卸载完已删除的磁盘后,磁盘状态为ready 2020-05-11 14:36:02 +08:00
Qu Xuan
b6ec2b406e fix: globalvpc count vpc 2020-05-11 14:17:09 +08:00
Qu Xuan
2560fa3457 fix: 避免aliyun磁盘计费类型多次转换 2020-05-11 14:00:32 +08:00
Qiu Jian
3b0bc38583 fix: create cloudaccount with disabled state 2020-05-11 12:44:23 +08:00
Zexi Li
1403fae69b Merge pull request #6219 from swordqiu/hotfix/qj-domain-sharing-bugfixes-20200508
fix: 1. vpc, cloudprovider should not violate the sharing limit of cl…
2020-05-11 12:37:31 +08:00
wanyaoqi
8144d2d2fb guest set login account 2020-05-11 10:48:39 +08:00
Zexi Li
70a4746afb Merge pull request #6252 from swordqiu/hotfix/qj-disk-no-valid-storage
fix: panic when disk has no valid storage_id
2020-05-11 10:00:45 +08:00
yunion-ci-robot
8bd0873c03 Merge pull request #6230 from tb365/bugfix/tb-bugfix-0508
Bugfix/tb bugfix 0508
2020-05-11 09:37:56 +08:00
yunion-ci-robot
f315557b5d Merge pull request #6237 from swordqiu/hotfix/qj-guestsecgroup-list-panic
fix: guestsecgroup-list panic
2020-05-11 03:07:52 +08:00
Qiu Jian
42171cb9c9 fix: panic when disk has no valid storage_id 2020-05-11 02:42:05 +08:00
Zexi Li
5be8df6a06 Merge pull request #6247 from wanyaoqi/bugfix/wyq/fix-import-from-libvirt
bugfix: fix import from libvirt
2020-05-10 21:34:29 +08:00
Zexi Li
e6be8f0167 Merge pull request #6232 from tb365/bugfix/tb-bugfix-0509
huawei network id fix
2020-05-10 21:33:15 +08:00
wanyaoqi
1ba2d92e66 fix import from libvirt 2020-05-10 20:41:37 +08:00
Zexi Li
2dd06d28cd Merge pull request #6200 from swordqiu/hotfix/qj-recode-cloud-sync-public-scope
Hotfix/qj recode cloud sync public scope
2020-05-10 19:50:05 +08:00
Zexi Li
a28646dea8 Merge pull request #6242 from yousong/bugfix/yousong-wording
disks: reword error message on bad DiskConfig struct
2020-05-10 11:28:44 +08:00
Yousong Zhou
749fd878bc disks: reword error message on bad DiskConfig struct 2020-05-10 00:15:14 +08:00
Qiu Jian
c209fdd97d feature: user login into project with highest privilege automatically 2020-05-09 23:52:52 +08:00
Qiu Jian
77f35bae2e fix: init sharing status of default vpc and default secgroup 2020-05-09 22:35:17 +08:00
Qiu Jian
bea90b4b19 fix: recode sync public_src of cloud resources 2020-05-09 21:26:01 +08:00
Qiu Jian
99ddc175ba fix: guestsecgroup-list panic 2020-05-09 21:18:32 +08:00
tangbin
002a618e79 huawei network id fix 2020-05-09 19:55:18 +08:00
tangbin
8c06b50ed9 new local lb backend fix 2020-05-09 19:21:39 +08:00
Zexi Li
ffd8ab638a Merge pull request #6221 from yousong/bugfix/yousong-proxysetting
multicloud: avoid changing transport of global default http client
2020-05-09 19:01:59 +08:00
Zexi Li
afeae6355d Merge pull request #6209 from swordqiu/hotfix/qj-domain-regional-cloud-resource-quota-keys
fix: missing methods for SDomainRegionalCloudResourceKeys
2020-05-09 18:59:57 +08:00
Zexi Li
38e22c3328 Merge pull request #6216 from swordqiu/hotfix/qj-export-bugfixes
fix: export missing keys && export panic
2020-05-09 18:58:52 +08:00
Zexi Li
41da2d94b8 Merge pull request #6213 from yousong/bugfix/yousong-vpcagent-route
vpcagent: ovn: explicitly include gateway route in classless routes
2020-05-09 18:56:58 +08:00
Zexi Li
7c8f37b441 Merge pull request #6211 from yousong/bugfix/yousong-vpcagent
vpcagent: models: ignore possible external guests
2020-05-09 18:55:28 +08:00
Zexi Li
0b6dea1d58 Merge pull request #6206 from wanyaoqi/bugfix/wyq/misc-fix-o5o8
bugfix: bm register use client token
2020-05-09 18:54:26 +08:00
Zexi Li
b9999687cf Merge pull request #6202 from rainzm/feat/ansible_playbook
Feat/ansible playbook
2020-05-09 18:54:10 +08:00
Rain
1fbfc7f220 feat/ansibleserver: Install git in Dockerfile.ansibleserver-base 2020-05-09 17:54:00 +08:00
Rain
cf514364eb feat/ansible_pb: Add climc operator for ansibleplaybooks_v2
1) ansibleplaybooksv2-run
2) ansibleplaybooksv2-stop
3) ansibleplaybooksv2-delete
2020-05-09 17:54:00 +08:00
Rain
faf32415fa feat/ansible_pb: Add IncludeRole implments 'ITask' in pkg/util/ansiblev2 2020-05-09 17:53:33 +08:00
Zexi Li
1cd7a34990 Merge pull request #6225 from yousong/bugfix/yousong-cloudnet
apigateway: handlers: register cloudnet modules
2020-05-09 17:52:30 +08:00
Zexi Li
453c7cde01 Merge pull request #6193 from zexi/hotfix/list-baremetal-scope-system
baremetal: find baremetal add scope system
2020-05-09 17:48:03 +08:00
Yousong Zhou
a70d17d6d0 apigateway: handlers: register cloudnet modules 2020-05-09 16:40:35 +08:00
Yousong Zhou
e711ae7648 multicloud: loader: guard against changing proxyFunc of default client 2020-05-09 11:59:34 +08:00
Yousong Zhou
fd3c9e5cd8 multicloud: avoid changing transport of global default http client 2020-05-09 11:28:10 +08:00
Yousong Zhou
a9061e5453 cloudprovider: add methods for getting http client
Prepare for following changes to avoid using and changing default
client settings
2020-05-09 11:27:50 +08:00
Qiu Jian
8bd0205bb6 fix: allow delete shared resource 2020-05-09 00:34:21 +08:00
Qiu Jian
f2e0fcf4e9 fix: 1. vpc, cloudprovider should not violate the sharing limit of cloud account 2.
sharing mode of host and attached local storage should be consistent. 3.
cannot change owner of shared resource
2020-05-08 23:27:28 +08:00
Qiu Jian
bfa8786767 fix: export missing keys && export panic 2020-05-08 17:25:17 +08:00
tangbin
4882a6bb2b lb acl cache add acl filter 2020-05-08 17:24:48 +08:00
Yousong Zhou
5caaccd43f vpcagent: ovn: explicitly include gateway route in classless routes 2020-05-08 16:29:14 +08:00
Yousong Zhou
4496a7bbcb vpcagent: models: ignore possible external guests 2020-05-08 15:35:23 +08:00
Qiu Jian
c7d58dee91 fix: missing methods for SDomainRegionalCloudResourceKeys 2020-05-08 14:08:31 +08:00
Zexi Li
0c45818c5c Merge pull request #6204 from tb365/bugfix/tb-apigateway-set-cookie-domain
set cookie domain
2020-05-08 11:57:18 +08:00
wanyaoqi
4f23ffb901 bm register use domain token 2020-05-08 11:56:40 +08:00
tangbin
f25bbee903 set cookie domain 2020-05-08 11:54:50 +08:00
Rain
331ba9bb37 feat/ansible_pb: Add support for requirements
You can declare the source info of the referenced role in requirements.
2020-05-08 11:08:32 +08:00
Zexi Li
068b9ec200 Merge pull request #6190 from tb365/feature/tb-apigateway-yunionauth-domain-setting
apigateway-yunionauth-domain-setting
2020-05-08 10:29:11 +08:00
Zexi Li
75fb380532 Merge pull request #6198 from swordqiu/hotfix/qj-fail-sync-share-state-for-on-premise
fix: fail to sync share state for on-premise storages
2020-05-08 10:18:16 +08:00
Zexi Li
2509a217ec Merge pull request #6194 from wanyaoqi/bugfix/wyq/minor-0507
bugfix: set host list scope system
2020-05-08 10:16:18 +08:00
Zexi Li
399c4ed874 Merge pull request #6196 from ioito/hotfix/qx-api-docs
fix: api doc(guests -> servers)
2020-05-08 10:15:57 +08:00
Qiu Jian
45b8494cdc fix: fail to sync share state for on-premise storages 2020-05-07 20:43:44 +08:00
zhaoxiangchun
cb13b2241c 修复规则无法禁用的问题 2020-05-07 20:35:55 +08:00
zhaoxiangchun
d874b52b0c bugfix mem paginate
通过totoal和offset 与limit比较确定最后返回数据
2020-05-07 20:35:55 +08:00
Qu Xuan
6cff98f85b fix: api doc(guests -> servers) 2020-05-07 20:12:24 +08:00
wanyaoqi
6779db23f3 set host list scope system 2020-05-07 20:02:15 +08:00
Zexi Li
10f9188a5f Merge pull request #6185 from zhaoxiangchun/bugfix/zxc-gcp-monitor
修复谷歌监控无法获取的问题
2020-05-07 17:21:05 +08:00
Zexi Li
c179d84336 Merge pull request #6192 from swordqiu/feature/qj-reorganize-climc-codes
feature: reorganize climc codes
2020-05-07 17:20:10 +08:00
Qiu Jian
1843ba334d feature: reorganize climc codes 2020-05-07 16:48:37 +08:00
Zexi Li
cfc9fcedde baremetal: find baremetal add scope system 2020-05-07 13:27:36 +08:00
Zexi Li
618e721114 Merge pull request #6183 from swordqiu/hotfix/qj-missing-public-private-actionlog
fix: missing perform public/private actionlog
2020-05-07 11:38:31 +08:00
tangbin
4e9264cb22 apigateway-yunionauth-domain-setting 2020-05-07 11:33:03 +08:00
Zexi Li
1637d81aee Merge pull request #6173 from wanyaoqi/feature/wyq/support-custom-service-url
mcclient: support custom service url
2020-05-07 11:28:53 +08:00
Zexi Li
2150286e28 Merge pull request #6181 from swordqiu/hotfix/qj-shared-cloudprovided-not-accessible
fix: shared cloudprovider not accessible
2020-05-07 11:28:18 +08:00
zhaoxiangchun
d4531972dd 修复谷歌监控无法获取的问题
直接返回调用RestAPI的json格式数据
2020-05-07 11:26:15 +08:00
Zexi Li
4e325d02b2 Merge pull request #6167 from swordqiu/feature/qj-decouple-metadata-standalone-resource
feature: decouple metadata resource and standalone resource
2020-05-07 11:25:02 +08:00
Zexi Li
f4edfb9e04 Merge pull request #6168 from yousong/bugfix/yousong-dnsrecords
dnsrecords: allow updating only description …
2020-05-07 11:23:00 +08:00
Zexi Li
7d3c4af10c Merge pull request #6179 from swordqiu/hotfix/qj-shared-resource-should-not-be-deletable
fix: shared resource should not be deletable
2020-05-07 11:18:10 +08:00
Zexi Li
f0fbe90d3b Merge pull request #6174 from swordqiu/hotfix/qj-get-real-client-ip
fix: fail to fetch real client ip from httprequest
2020-05-07 11:16:11 +08:00
Qiu Jian
c473c9299e fix: missing perform public/private actionlog 2020-05-07 02:13:10 +08:00
Qiu Jian
a2a60245b2 fix: shared cloudprovider not accessible 2020-05-07 01:52:18 +08:00
Qiu Jian
6f3e18930e fix: shared resource should not be deletable 2020-05-07 01:37:41 +08:00
Qiu Jian
5ff4b9748b fix: fail to fetch real client ip from httprequest 2020-05-06 22:22:29 +08:00
wanyaoqi
26780e2c8b support custom service url 2020-05-06 22:13:58 +08:00
Yousong Zhou
2f056b9ef0 dnsrecords: allow updating only description
This commit includes the following changes

 - Eliminate unused arguments from validateModelData()
 - Remove "records" member of input data unconditionally
 - Allow updates to not include records related parameters, to allow
   updating only "description" without emitting "Empty record" error
2020-05-06 18:39:39 +08:00
Yousong Zhou
06abfccbbc dnsrecords: note that DnsRecordManager is a IAdminSharableVirtualModelManager 2020-05-06 18:39:39 +08:00
yunion-ci-robot
68bcd4f6e5 Merge pull request #6158 from zhaoxiangchun/bugfix/zxc-paginate
bugfix mem paginate
2020-05-06 15:43:44 +08:00
Qiu Jian
722498bf9e feature: decouple metadata resource and standalone resource 2020-05-06 15:38:18 +08:00
zhaoxiangchun
7c0d704148 bugfix mem paginate
通过totoal和offset 与limit比较确定最后返回数据
2020-05-06 11:01:16 +08:00
Zexi Li
d39d146258 Merge pull request #6153 from ioito/hotfix/qx-secgroup-cache-filter
fix: secgroupcache权限问题修复
2020-04-30 20:13:48 +08:00
Zexi Li
b4dd1d1eee Merge pull request #6151 from wanyaoqi/bugfix/wyq/minor-fix-0430
fix host details output
2020-04-30 19:08:15 +08:00
wanyaoqi
9652c97dce fix host init without etcd 2020-04-30 18:45:16 +08:00
Qu Xuan
10469342bb fix: secgroupcache权限问题修复 2020-04-30 15:31:36 +08:00
wanyaoqi
db2d02fe00 fix host details output 2020-04-30 15:04:59 +08:00
Zexi Li
8e55ffa23e Merge pull request #6147 from rainzm/fix/scaling_notification
fix/monitor: AutoScalingNotifier.ShouldNotify should call NotifierBase.ShouldNotify
2020-04-30 14:41:27 +08:00
Zexi Li
647aec25ce Merge pull request #6145 from wanyaoqi/hotfix/wyq/host-health-fix
host health check fix
2020-04-30 14:40:55 +08:00
Zexi Li
85fa63fab6 Merge pull request #6150 from wanyaoqi/bugfix/wyq/fix-update-input
bugfix: fix update input
2020-04-30 14:40:27 +08:00
wanyaoqi
7353622d23 fix update input 2020-04-30 11:38:15 +08:00
wanyaoqi
d727248929 fix host health 2020-04-30 11:32:16 +08:00
Rain
e67effaf3f fix/monitor: AutoScalingNotifier.ShouldNotify should call NotifierBase.ShouldNotify 2020-04-30 11:26:02 +08:00
Zexi Li
8c49248d02 Merge pull request #6123 from ioito/hotfix/qx-usage-optimized
fix: usage-handler 不统计虚拟的vpc wire
2020-04-30 10:36:02 +08:00
Zexi Li
b5d305d8bd Merge pull request #6137 from ioito/hotfix/qx-cloudaccount-create
fix: 云账号创建可以指定项目
2020-04-30 10:35:54 +08:00
Zexi Li
79fe55a600 Merge pull request #6141 from swordqiu/hotfix/qj-remove-cloud-account-sync-randomness
fix: remove cloudaccount autosync randomness
2020-04-30 10:35:30 +08:00
Zexi Li
d494c331c2 Merge pull request #6143 from swordqiu/hotfix/qj-list-lbbg-panic
fix: list lbbg panic
2020-04-30 10:35:00 +08:00
Qiu Jian
34aacdcde7 fix: list lbbg panic 2020-04-29 22:41:12 +08:00
Qiu Jian
0e03bfc275 fix: remove cloudaccount autosync randomness 2020-04-29 22:27:13 +08:00
Zexi Li
7a1f1ec922 Merge pull request #6120 from swordqiu/hotfix/qj-sysadmin-override-policy-violation
Hotfix/qj sysadmin override policy violation
2020-04-29 21:15:30 +08:00
Zexi Li
efafdbbd46 Merge pull request #6124 from tb365/feature/tb-apigateway-cookies-add-domain-setting
add cookie domain setting option
2020-04-29 21:13:24 +08:00
Zexi Li
76ede775b6 Merge pull request #6135 from zexi/feature/k8s-monitor-component
climc: k8s component add monitor options
2020-04-29 21:12:49 +08:00
Qu Xuan
c12c489e9f fix: 云账号创建可以指定项目 2020-04-29 20:04:53 +08:00
Zexi Li
ec8b24ed03 Merge pull request #6121 from zhaoxiangchun/bugfix/zxc-monitor-nodata-email
monitor服务:对于监控数据nodata情况,默认不发送邮件
2020-04-29 19:35:56 +08:00
Zexi Li
8df1559162 climc: k8s component add monitor options 2020-04-29 18:04:42 +08:00
Qiu Jian
b1647e7ebf fix: sysadmin can override policy violation check 2020-04-29 17:57:36 +08:00
tangbin
849d1d6699 add cookie domain setting option 2020-04-29 17:35:41 +08:00
Qu Xuan
d66197068d fix: usage-handler 不统计虚拟的vpc wire 2020-04-29 15:58:03 +08:00
zhaoxiangchun
e81334c0a7 monitor,对于监控数据nodata,默认不发送邮件 2020-04-29 15:17:54 +08:00
Zexi Li
4d1b93e29e Merge pull request #6118 from swordqiu/hotfix/qj-fix-cloud-account-usage-vpc
fix: cloud-account-usage vpc/storage not accurate
2020-04-29 13:11:31 +08:00
Zexi Li
1e6a4fce2f Merge pull request #6101 from rainzm/fix/auto_scaling10
Fix/Auto Scaling
2020-04-29 13:09:26 +08:00
Zexi Li
82c0de3ef4 Merge pull request #6095 from ioito/hotfix/qx-rds-password
fix: 普通用户可获取rds账号密码
2020-04-29 13:07:46 +08:00
Zexi Li
c11165ddb9 Merge pull request #6109 from ioito/hotfix/qx-gcp-os-mkdir
fix: 避免gcp创建创建文件夹失败
2020-04-29 13:07:23 +08:00
Zexi Li
d4c7e62add Merge pull request #6111 from swordqiu/hotfix/qj-prevent-policy-violation
fix: prevent policy violation
2020-04-29 13:07:04 +08:00
Zexi Li
d32cbd0088 Merge pull request #6116 from swordqiu/hotfix/qj-export-data-duplicate-key-error
fix: export files complain duplicate field name error
2020-04-29 13:06:28 +08:00
Qiu Jian
f39f838166 fix: cloud-account-usage vpc/storage not accurate 2020-04-29 01:14:29 +08:00
Qiu Jian
5c138b9199 fix: export files complain duplicate field name error 2020-04-29 00:53:44 +08:00
yunion-ci-robot
5fe7b53699 Merge pull request #6103 from ioito/bugfix/qx-openstack-storage-sync
fix: 修复openstack存储同步问题
2020-04-28 23:35:34 +08:00
Qiu Jian
ecb483b9be fix: prevent policy violation 2020-04-28 23:28:29 +08:00
Qu Xuan
b805d3495a fix: 避免gcp创建创建文件夹失败 2020-04-28 20:43:33 +08:00
Zexi Li
91e9f91c10 Merge pull request #6092 from wanyaoqi/feature/wyq/gpu-host-enable-hugepage
feature: gpu host enable huge page
2020-04-28 16:04:40 +08:00
Zexi Li
464d689697 Merge pull request #6034 from wanyaoqi/feature/wyq/enable-etcd-lock2
Feature/wyq/enable etcd lock2
2020-04-28 16:01:42 +08:00
Qu Xuan
e43af577b6 fix: 修复openstack存储同步问题 2020-04-28 14:45:26 +08:00
Rain
352e912c29 fix/as: Set ScalingPolicy's project as its ScalingGroup's project 2020-04-28 11:13:59 +08:00
Qu Xuan
0ff17ebeff fix: 普通用户可获取rds账号密码 2020-04-28 10:34:35 +08:00
wanyaoqi
5158a509ee enable etcd lock 2020-04-28 10:33:13 +08:00
wanyaoqi
38c1c70a27 host health check 2020-04-28 10:33:12 +08:00
yunion-ci-robot
0537897fb4 Merge pull request #6094 from zexi/bugfix/climc-completion
climc: remove stale zsh completion code
2020-04-27 22:05:33 +08:00
Zexi Li
16adec3a5b climc: remove stale zsh completion code 2020-04-27 21:07:34 +08:00
Zexi Li
b6562f1d27 Merge pull request #6085 from yousong/bugfix/yousong-proxysetting
region: cloudaccounts: re-validate only when proxysetting changed
2020-04-27 20:59:09 +08:00
Zexi Li
94cb6bc029 Merge pull request #6090 from yousong/bugfix/yousong-vpc-distgw
vpcagent: tmp replacement for db.FindByIndex()
2020-04-27 20:51:59 +08:00
Yousong Zhou
503735ebf5 vpcagent: ad-hoc replacement for db.FindByIndex() 2020-04-27 20:06:47 +08:00
wanyaoqi
98377116f3 gpu host enable huge page 2020-04-27 20:02:22 +08:00
Yousong Zhou
d716405eb9 region: cloudaccounts: re-validate only when proxysetting changed 2020-04-27 17:26:08 +08:00
Zexi Li
58d9018092 Merge pull request #6075 from yousong/bugfix/yousong-vpc-distgw
vpcagent: work around nics of pending deleted guest
2020-04-27 17:18:42 +08:00
Zexi Li
535b5a522f Merge pull request #6079 from ioito/hotfix/qx-gcp-region-status
fix: gcp fake region status
2020-04-27 17:17:36 +08:00
Zexi Li
8cd94f472c Merge pull request #6077 from swordqiu/hotfix/qj-cloud-account-usage-not-accurate
fix: cloudaccount usage region/zone count not accurate
2020-04-27 17:16:53 +08:00
Zexi Li
a426100b50 Merge pull request #6024 from zhaoxiangchun/feature/zxc-suggest-mon
lb 负载均衡优化建议
2020-04-27 17:16:09 +08:00
Zexi Li
75801db65b Merge pull request #6081 from wanyaoqi/bugfix/wyq/fix-esxi-convert-diskpath
bugfix: fix exsi convert disk path
2020-04-27 17:14:23 +08:00
Zexi Li
1f343877b9 Merge pull request #6083 from zexi/feature/k8s-monitor-component
climc: add k8s monitor component
2020-04-27 17:13:41 +08:00
Yousong Zhou
09cc38f962 vpcagent: models: allow guest to have multiple vpc nics 2020-04-27 17:08:21 +08:00
Yousong Zhou
11835889c0 vpcagent: work around nics of pending deleted guest 2020-04-27 16:56:44 +08:00
Rain
be5c539e94 fix/autoscaling: Chang the format of CoolingTime 2020-04-27 16:10:17 +08:00
Zexi Li
90618466b2 climc: add k8s monitor component 2020-04-27 16:08:39 +08:00
Zexi Li
5fdf202b40 Merge pull request #6068 from ioito/hotfix/qx-google-subaccount
fix: gcp use project name for cloudprovider
2020-04-27 16:03:04 +08:00
Qu Xuan
86251d1ca3 fix: gcp fake region status 2020-04-27 15:55:07 +08:00
wanyaoqi
9c4d3c62b3 fix exsi convert disk path 2020-04-27 15:54:17 +08:00
Qiu Jian
8d7bc247c9 fix: cloudaccount usage region/zone count not accurate 2020-04-27 15:52:47 +08:00
yunion-ci-robot
adc5138781 Merge pull request #6073 from rainzm/fix/eamil_verify_url
fix/notify: remove 'v2' from email verify url
2020-04-27 14:38:32 +08:00
Qu Xuan
139b9592c8 fix: gcp use project name for cloudprovider 2020-04-27 14:15:38 +08:00
Zexi Li
230ef05484 Merge pull request #5853 from wanyaoqi/feature/wyq/host-health2
host health check
2020-04-27 12:55:05 +08:00
Zexi Li
75a4d01a59 Merge pull request #6062 from rainzm/fix/notify_timeout
fix/notify: Add deadline for rpc client
2020-04-27 12:47:57 +08:00
yunion-ci-robot
cbab5be0cc Merge pull request #6041 from tb365/bugfix/tb-yunionapi-fix-0426
yunionapi reset password fix
2020-04-27 12:07:31 +08:00
Rain
9aa132cf37 fix/notify: remove 'v2' from email verify url 2020-04-27 11:30:35 +08:00
Zexi Li
7f96ad4844 Merge pull request #6059 from swordqiu/hotfix/qj-cloud-account-usage-fix
fix: cloud-account/provider usage not accurate
2020-04-27 10:55:06 +08:00
Zexi Li
f33f48ef43 Merge pull request #6052 from wanyaoqi/bugfix/wyq/minor-fix200426
region: fix host cmt bound, minor fix
2020-04-27 10:54:37 +08:00
Zexi Li
bc61d77f45 Merge pull request #6050 from swordqiu/feature/qj-baremetal-options-management
feature: make baremetal options managed by service config
2020-04-27 10:53:22 +08:00
Zexi Li
92cad6e8c8 Merge pull request #6054 from rainzm/fix/auto_scaling9
Fix/auto scaling & guest template
2020-04-27 10:52:03 +08:00
Rain
e1c63729d9 fix/notify: Add deadline for rpc client 2020-04-27 10:41:45 +08:00
Qiu Jian
912bf5c699 fix: cloud-account/provider usage not accurate 2020-04-27 02:10:23 +08:00
wanyaoqi
af6c6fee88 host health check 2020-04-26 21:44:02 +08:00
tangbin
32e4ae98ca yunionapi reset password fix 2020-04-26 21:34:32 +08:00
Qiu Jian
ee9289c231 feature: make baremetal options managed by service config 2020-04-26 21:24:21 +08:00
Zexi Li
bc12970351 Merge pull request #6042 from tb365/bugfix/tb-elb-bugfix-0426
Bugfix/tb elb bugfix 0426
2020-04-26 21:06:06 +08:00
Zexi Li
a781e95042 Merge pull request #6022 from yousong/bugfix/yousong-vpc-distgw
vpcagent: fend off non-onecloud-vpc guest nics
2020-04-26 21:04:25 +08:00
Zexi Li
96ec33d1cf Merge pull request #6020 from swordqiu/hotfix/qj-opslog-fetch-owner-id-fail
fix: opslog FetchOwnerId fail
2020-04-26 21:03:51 +08:00
Rain
09d7aaf392 fix/autoscaling: Change Sunday as 7 from 0 2020-04-26 20:59:50 +08:00
Rain
203bdb2dfb fix/guesttemplate: Change ResetPassword as true default 2020-04-26 20:59:50 +08:00
Rain
4d8e0ba1b4 fix/autoscaling: fix some problem
1. ScalingGroupGuestManger.Query 默认添加 NotEqual(...)
2. ScalingGroup.Scale 扩大锁的粒度,更新冷却时间也挪到这里面
3. climc 中增加 scaling-group-show
2020-04-26 20:59:44 +08:00
wanyaoqi
b05d22834f host fix cmt bound, minor fix 2020-04-26 20:52:42 +08:00
Zexi Li
d0fee09382 Merge pull request #6040 from tb365/bugfix/tb-ctyun-subnet-fix-0426
ctyun subnet create bugfix
2020-04-26 20:31:12 +08:00
tangbin
7b6f45789b aws elb health check type fix 2020-04-26 20:04:40 +08:00
Zexi Li
03824a1f22 Merge pull request #6013 from swordqiu/hotfix/qj-network-allocate-shared-ipaddr
fix: network allocation according to sharing status
2020-04-26 19:58:50 +08:00
yunion-ci-robot
95978b2f44 Merge pull request #6036 from swordqiu/hotfix/qj-proxysetting-domain-privilege
fix: proxysetting attributes should be domain-settable
2020-04-26 19:58:42 +08:00
Zexi Li
1b15eb51b2 Merge pull request #6038 from wanyaoqi/bugfix/wyq/minor-fix200426
region misc bugfix:
2020-04-26 19:57:36 +08:00
tangbin
b62727ae05 huawei elb cookie timeout fix 2020-04-26 19:53:13 +08:00
yunion-ci-robot
853d3a6a7e Merge pull request #6008 from swordqiu/hotfix/qj-get-on-premise-underlay-network
fix: GetOnPremiseNetworkOfIP should return underlay networks
2020-04-26 19:48:33 +08:00
tangbin
8618be1fd2 ctyun subnet create bugfix 2020-04-26 19:04:37 +08:00
Yousong Zhou
06ea1b1706 guestnetworks: try allocation of mapped addr on sync 2020-04-26 18:52:58 +08:00
Yousong Zhou
25d1c36932 region: vpcs_mapped_address: fix locking 2020-04-26 18:52:58 +08:00
Yousong Zhou
138b596ec4 region: vpcs_mapped_address: alloc guestnic mapped addr backwards 2020-04-26 18:52:58 +08:00
Yousong Zhou
64f269ac2f guests: simplify code 2020-04-26 18:52:58 +08:00
Yousong Zhou
0e16bf8ff4 hostman: options: pack up a Parse() func 2020-04-26 18:52:58 +08:00
Yousong Zhou
16ced399a5 vpcagent: fend off non-onecloud-vpc guest nics 2020-04-26 18:52:58 +08:00
wanyaoqi
9a7c7623cd misc bugfix:
- fix get details hosts
- save image enable generate_name
- network auto set dns
- fix servers filter by disk
2020-04-26 18:31:55 +08:00
Zexi Li
c7d5c761ac Merge pull request #6028 from ioito/bugfix/qx-openstack-sync
fix: json unmarshal
2020-04-26 18:19:00 +08:00
Qiu Jian
6faa4d91a1 make DIRECT proxysettting default share to system 2020-04-26 17:33:39 +08:00
Qiu Jian
1e81c79adf fix: proxysetting attributes should be domain-settable 2020-04-26 16:50:51 +08:00
Zexi Li
b1db63dae2 Merge pull request #6006 from swordqiu/hotfix/qj-gcp-account-project-id-name-conflict
Hotfix/qj gcp account project id name conflict
2020-04-26 16:36:03 +08:00
Qu Xuan
b48dbbc5c8 fix: json unmarshal 2020-04-26 15:50:32 +08:00
Qiu Jian
d4600430a5 fix: resolve parameter name conflict in google cloud account create
input
2020-04-26 11:42:18 +08:00
zhaoxiangchun
fc05c2d0e9 lb 负载均衡优化建议
通过判断是否包含后端服务器组和后端服务实例进行判断
2020-04-26 11:38:11 +08:00
Qiu Jian
1882232b4c fix: opslog FetchOwnerId fail 2020-04-26 11:35:59 +08:00
Qiu Jian
68c03778a2 fix: network allocation according to sharing status 2020-04-26 00:36:30 +08:00
yunion-ci-robot
74eef22025 Merge pull request #6014 from zexi/hotfix/scheduler-free-port
scheduler: fix network predicate get wrong free port
2020-04-26 00:28:32 +08:00
Zexi Li
f39c829595 scheduler: fix network predicate get wrong free port 2020-04-25 23:23:43 +08:00
Qiu Jian
2498af7c38 fix: GetOnPremiseNetworkOfIP should return underlay networks 2020-04-25 16:27:53 +08:00
Zexi Li
e7550b781d Merge pull request #6004 from swordqiu/hotfix/qj-name-validator-revisited
fix: dns name pattern revisited
2020-04-25 10:44:27 +08:00
Zexi Li
1ca876b163 Merge pull request #6007 from swordqiu/hotfix/qj-update-api-docs-url
fix: update README api docs url to v2
2020-04-25 10:42:54 +08:00
Qiu Jian
5f4f11bee4 fix: update README api docs url to v2 2020-04-24 23:33:26 +08:00
Qiu Jian
61051b843f fix: dns name pattern revisited 2020-04-24 21:52:09 +08:00
yunion-ci-robot
b75dcf6107 Merge pull request #5911 from yousong/feature/yousong-vpc-distgw
Feature/yousong vpc distgw
2020-04-24 21:08:29 +08:00
Zexi Li
0d79d42e28 Merge pull request #6002 from swordqiu/hotfix/qj-fix-document-gen-codes
fix: code autogen issues
2020-04-24 20:33:10 +08:00
Zexi Li
a725b53641 Merge pull request #5978 from rainzm/fix/auto_scaling8
Fix/Auto Scaling
2020-04-24 20:30:19 +08:00
Qiu Jian
7ab3a06b46 fix: code autogen issues 2020-04-24 20:19:43 +08:00
Rain
16226becf7 fix/autoscaling: Add 'scaling_group_id' for server-list result 2020-04-24 19:33:59 +08:00
Rain
32280e2145 fix/autoscaling: Add status 'pending_remove' for ScalingGroup_Guest
The status 'pending_remove' means that the guest described by
ScalingGroup_Guest has been pendingdeleted or deleted.
2020-04-24 19:33:46 +08:00
Yousong Zhou
f05e16bd1b hostman: let sdnagent do port cleanup
ovsutils.CleanHiddenPorts() is buggy in that it has no regards for
patch ports
2020-04-24 18:32:09 +08:00
Yousong Zhou
279e68ae09 hostman: options: add ovn_mapped_bridge 2020-04-24 18:32:09 +08:00
Yousong Zhou
5acbec4529 hostman: options: add allow_xx_vms 2020-04-24 18:32:09 +08:00
Yousong Zhou
d2c0ba4d5a vpcagent: ovn: use network.GuestDns when available 2020-04-24 18:32:09 +08:00
Yousong Zhou
05c38c8130 vpcagent: ovn: manage static routes 2020-04-24 18:32:08 +08:00
Yousong Zhou
0578d6c498 vpcagent: ovn: guestnetwork: guard against empty dhcpopt 2020-04-24 18:32:08 +08:00
Yousong Zhou
1c50ffb216 vpcagent: ovn: rename subnet, guestnetwork ovn obj names 2020-04-24 18:32:08 +08:00
Yousong Zhou
38354229b8 vpcagent: ovn: use cmp() when claimVpc 2020-04-24 18:32:08 +08:00
Yousong Zhou
d8e419cfae vpcagent: ovn: use cmp() 2020-04-24 18:32:08 +08:00
Yousong Zhou
4d3eba9bac vpcagent: add cmp() for search and pre-cleanup 2020-04-24 18:32:08 +08:00
Yousong Zhou
e6bb3397d1 vpcagent: ovn: make host ls when claimVpc 2020-04-24 18:32:08 +08:00
Yousong Zhou
e4ad3f4194 vpcagent: models: include guest, host 2020-04-24 18:32:08 +08:00
Yousong Zhou
ff2686689c guests: always include host_id in desc 2020-04-24 18:32:08 +08:00
Yousong Zhou
9990ad3bcc guestnetworks: add vpc id and mapped ip addr info to nic desc 2020-04-24 18:32:08 +08:00
Yousong Zhou
3142957f5b guestnetworks,hosts: add alloc mapped ip addr for use in onecloud vpc 2020-04-24 18:32:08 +08:00
Yousong Zhou
12639e027b apis: add ovn distgw const definitions 2020-04-24 18:32:08 +08:00
Zexi Li
fd82d1ed0f Merge pull request #5995 from yousong/bugfix/yousong-lb
lblistener: fix updating lblistener without backend_group field
2020-04-24 18:17:10 +08:00
Zexi Li
5be072b7c9 Merge pull request #5993 from yousong/bugfix/yousong-misc
cloudcommon: allow create:"domain" tag
2020-04-24 14:45:34 +08:00
Yousong Zhou
1224cd819f lblistener: fix updating lblistener without backend_group field
Fixes dd01610931 ("lblistener: allow setting http/https listener
backendgroup to empty")
2020-04-24 14:21:25 +08:00
Yousong Zhou
14389667a4 cloudcommon: allow create:"domain" tag
Fixes panic: model manager hosts: column manager_uri has invalid tag
create:"domain", expecting [required optional domain_required
domain_optional admin_required admin_optional]
2020-04-24 14:13:30 +08:00
Zexi Li
7688a13453 Merge pull request #5985 from ioito/hotfix/qx-rds-optimized
fix: 避免rds任务交叉运行
2020-04-24 14:10:48 +08:00
Qu Xuan
5754fe90c5 fix: 避免rds任务交叉运行 2020-04-24 11:27:38 +08:00
Zexi Li
69ae7cab65 Merge pull request #5971 from rainzm/fix/guest_disk
feat(region): Structured diskinfo and add 'Id', 'Name' field
2020-04-24 11:22:01 +08:00
Zexi Li
30bbae6979 Merge pull request #5982 from swordqiu/hotfix/qj-domain-resource-fields-use-domain-tags
fix: domain resources' field tags should changed to domain tags
2020-04-24 11:15:07 +08:00
Zexi Li
681cc963b2 Merge pull request #5984 from zexi/feature/climc-zsh-completion
climc: support zsh completion
2020-04-24 11:14:20 +08:00
Zexi Li
e884f4b6f0 climc: support zsh completion 2020-04-24 01:48:00 +08:00
Zexi Li
1ff15c33b9 Merge pull request #5960 from swordqiu/hotfix/qj-opslog-create-fail
Hotfix/qj opslog create fail
2020-04-24 01:37:18 +08:00
Zexi Li
0493932f94 Merge pull request #5975 from ioito/hotfix/cloud-event-filter
fix: 添加cloudevent过滤参数
2020-04-24 01:36:10 +08:00
Zexi Li
fef17c5106 Merge pull request #5979 from ioito/hotfix/qx-cloudevent-sync-optimized
fix: cloudevent使用代理优化
2020-04-24 01:35:04 +08:00
Qiu Jian
ee42b9c014 fix: domain resources' field tags should changed to domain tags 2020-04-23 22:10:22 +08:00
yunion-ci-robot
7ff622b740 Merge pull request #5973 from tb365/bugfix/tb-bugfix-0423
aliyun create elb listener fix
2020-04-23 20:23:53 +08:00
Rain
8c4b025dc3 feat(region): Structured diskinfo and add 'Id', 'Name' field 2020-04-23 18:01:30 +08:00
Qu Xuan
cea9cf95b5 fix: cloudevent使用代理优化 2020-04-23 17:52:43 +08:00
Rain
39d5603af8 fix/autoscaling: Change ScalingPolicy as VirtualResource 2020-04-23 17:23:45 +08:00
Rain
acb4d1cabe fix/autoscaling: Use UserCred's session but AdminSession to request monitor 2020-04-23 17:21:21 +08:00
Qu Xuan
a5b6e894b4 fix: 添加cloudevent过滤参数 2020-04-23 17:11:44 +08:00
tangbin
a06f7e7b50 aliyun create elb listener fix 2020-04-23 16:29:36 +08:00
yunion-ci-robot
8cbae70a50 Merge pull request #5915 from ioito/hotfix/qx-project-sync
fix: 自动创建项目
2020-04-23 13:39:51 +08:00
Qiu Jian
1b861a41f9 fix: opslog create fail 2020-04-23 11:07:05 +08:00
Zexi Li
cbf5ef8547 Merge pull request #5966 from swordqiu/feature/qj-redfish-supermicro-support
supermicro redfish support
2020-04-23 09:52:59 +08:00
Qiu Jian
98cec09a63 supermicro redfish support 2020-04-23 09:25:19 +08:00
Zexi Li
c34b27a563 Merge pull request #5928 from yousong/bugfix/yousong-lbagent
lbagent: fend off unexpected resources just in case
2020-04-23 00:06:48 +08:00
Zexi Li
4bf9112c99 Merge pull request #5958 from wanyaoqi/bugfix/wyq/fix-check-ca-cert
fix check ca cert
2020-04-23 00:05:30 +08:00
Zexi Li
7b8a098a61 Merge pull request #5944 from rainzm/fix/auto_scaling7
fix(region): Add implements about owner for ScalingPolicy and ScalingActivity
2020-04-23 00:04:07 +08:00
Zexi Li
231ffc2a6d Merge pull request #5921 from swordqiu/hotfix/qj-find-anonymous-struct-needs-pointer
fix: FindAnonymousStructPoint needs input as a pointer to struct
2020-04-23 00:02:22 +08:00
Zexi Li
f74a74c35b Merge pull request #5918 from ioito/hotfix/qx-huawei-project
fix: 修复华为云eneterprise-project-list异常问题
2020-04-23 00:01:40 +08:00
Zexi Li
e5d6479b46 Merge pull request #5919 from ioito/hotfix/qx-public-region-sync-name
fix: 非私有云同步region name
2020-04-22 23:59:29 +08:00
Zexi Li
fb0ccca7b4 Merge pull request #5956 from wanyaoqi/feature/wyq/add-sync-disk-snapshot-status
support sync disk snapshot status
2020-04-22 23:58:27 +08:00
Zexi Li
6f01d26471 Merge pull request #5931 from ioito/hotfix/qx-azure-vm-disk-sync
fix: 转换非标准存储类型到lrs
2020-04-22 23:57:08 +08:00
Zexi Li
4d95879a26 Merge pull request #5945 from tb365/bugfix/tb-bugfix-042201
huawei elb sync vpc
2020-04-22 23:55:24 +08:00
Zexi Li
a1fa14e62e Merge pull request #5961 from swordqiu/hotfix/qj-clean-validate-create-data-pending-usage
fix: clean pending usage caused by pre-validate-create-data
2020-04-22 23:54:09 +08:00
Zexi Li
53814a93cf Merge pull request #5951 from zexi/hotfix/baremetal-ipmi-reboot
baremetal: ensure power up add retries
2020-04-22 23:50:30 +08:00
Qiu Jian
2297c6e963 fix: clean pending usage caused by pre-validate-create-data 2020-04-22 23:38:08 +08:00
Zexi Li
5693ae05da baremetal: ensure power up add retries 2020-04-22 22:05:49 +08:00
wanyaoqi
cf0cf484ae fix check ca cert 2020-04-22 21:59:43 +08:00
wanyaoqi
54596fc429 support sync disk snapshot status 2020-04-22 20:53:12 +08:00
tangbin
bd0a8f709b huawei elb sync vpc 2020-04-22 20:26:55 +08:00
Rain
6e9366f569 fix(region): Add implements about owner for ScalingPolicy and ScalingActivity 2020-04-22 20:23:56 +08:00
Qiu Jian
f82543e236 fix: lb FetchCustomizedColumes fixes 2020-04-22 20:19:39 +08:00
yunion-ci-robot
5d4f7eabee Merge pull request #5927 from tb365/bugfix/tb-bugfix-0422
remove aws invalid backendgroup
2020-04-22 19:50:51 +08:00
Qu Xuan
0f2e997f6d fix: 转换非标准存储类型到lrs 2020-04-22 18:52:35 +08:00
Yousong Zhou
7f982d5b29 lbagent: fend off unexpected resources just in case
As resource we do not know whether they are bad, but surely we know
they are not what we expect
2020-04-22 18:46:18 +08:00
Qiu Jian
b7b496676e fix: is_managed filter is not accurate 2020-04-22 18:35:07 +08:00
tangbin
674764208c remove aws invalid backendgroup 2020-04-22 18:29:26 +08:00
Qiu Jian
ead8825dc2 fix: FindAnonymousStructPoint needs input as a pointer to struct 2020-04-22 18:04:04 +08:00
Qu Xuan
86087b9acb fix: 非私有云同步region name 2020-04-22 17:58:20 +08:00
Zexi Li
e55bb827a1 Merge pull request #5916 from rainzm/fix/host_tag
fix(host): No tag when tag's value is empty
2020-04-22 17:41:01 +08:00
Zexi Li
941e16659f Merge pull request #5913 from rainzm/fix/auto_scaling6
fix(region): Fix problems for Auto Scaling
2020-04-22 17:38:12 +08:00
yunion-ci-robot
0ad74a1d8f Merge pull request #5879 from wanyaoqi/feature/wyq/keystone-store-service-cert
keystone store service cert
2020-04-22 17:36:52 +08:00
Qu Xuan
4d71f7e2a3 fix: 修复华为云eneterprise-project-list异常问题 2020-04-22 16:57:22 +08:00
Rain
72716b8d5b fix(host): No tag when tag's value is empty 2020-04-22 16:46:09 +08:00
wanyaoqi
b682e1b44e keystone store service cert 2020-04-22 16:37:42 +08:00
Qu Xuan
72fb9a58d0 fix: 自动创建项目 2020-04-22 16:33:44 +08:00
Rain
4f27908fff fix(region): Fix problems for Auto Scaling
1. ScalingPolicyManager and ScalingActivityManager override ResourceScope.
2. Change 'tenant' as 'project_id' before requesting to forcast.
2020-04-22 16:30:46 +08:00
Zexi Li
087a2a1ef3 Merge pull request #5900 from ioito/hotfix/qx-google-retry
fix: 尽量避免因代理问题导致google request异常
2020-04-22 15:11:54 +08:00
Zexi Li
c45279ddd9 Merge pull request #5903 from ioito/hotfix/qx-resouce-group
fix: esxi disk project sync
2020-04-22 15:10:54 +08:00
Zexi Li
d868de668e Merge pull request #5904 from swordqiu/hotfix/qj-not-share-project-resource-by-default
fix: do not share porject resource by default
2020-04-22 15:10:25 +08:00
Zexi Li
5838b7ecc6 Merge pull request #5906 from swordqiu/hotfix/qj-blacklist-keystone-reset-admin-pass-option
fix: blacklist keystone reset admin password
2020-04-22 15:06:40 +08:00
Qiu Jian
7655f8e2a2 fix: blacklist keystone reset admin password 2020-04-22 15:00:18 +08:00
Qiu Jian
ea254c8ed8 fix: do not share porject resource by default 2020-04-22 11:50:33 +08:00
Qu Xuan
039644e89f fix: esxi disk project sync 2020-04-22 11:02:39 +08:00
Qu Xuan
f7bf34ee18 fix: 尽量避免因代理问题导致google request异常 2020-04-22 10:47:27 +08:00
Zexi Li
5256c0f5d7 Merge pull request #5890 from swordqiu/hotfix/qj-policy-details-updated-created-time
fix: policy details should carry updated_at and created_at fields
2020-04-22 10:34:20 +08:00
Zexi Li
548e36a140 Merge pull request #5895 from swordqiu/hotfix/qj-delete-idp-clean-users
fix: delete idp also delete users/groups in target domain
2020-04-22 10:33:37 +08:00
Zexi Li
a952d7f8e5 Merge pull request #5884 from ioito/hotfix/qx-external-project-sync
fix: 仅当变更domainId时才需要更新projectId
2020-04-22 10:32:17 +08:00
Zexi Li
fe68b9598f Merge pull request #5882 from swordqiu/feature/qj-climc-support-auth-by-token
feature: climc support auth by token
2020-04-22 10:31:56 +08:00
Zexi Li
931edc6e79 Merge pull request #5881 from ioito/hotfix/qx-resouce-group
Hotfix/qx resouce group
2020-04-22 10:31:40 +08:00
Qiu Jian
3118a1020f fix: delete idp also delete users/groups in target domain 2020-04-21 23:47:42 +08:00
Qiu Jian
4c313f5a26 fix: policy details should carry updated_at and created_at fields 2020-04-21 22:37:06 +08:00
Qu Xuan
1ef9a481c3 VMware resource pool同步 2020-04-21 21:17:14 +08:00
Qu Xuan
bf57b829ae fix: 仅当变更domainId时才需要更新projectId 2020-04-21 21:12:56 +08:00
Qiu Jian
7de51b9d70 feature: climc support auth by token 2020-04-21 18:37:04 +08:00
Qu Xuan
3a0b5c5e21 fix: 华为企业项目映射同步 2020-04-21 18:34:51 +08:00
Qu Xuan
f5ed692171 fix: 阿里云资源组同步 2020-04-21 16:17:40 +08:00
Zexi Li
d9575b2078 Merge pull request #5875 from swordqiu/hotfix/qj-list-item-export-recode
fix: list item export recode
2020-04-21 13:03:29 +08:00
Qiu Jian
880b0ecf4d fix: list item export recode 2020-04-21 11:45:36 +08:00
Zexi Li
3d70163ee9 Merge pull request #5873 from swordqiu/hotfix/qj-misc-bugfix-20200420
fix: cloudaccount is created as system shared by default
2020-04-21 10:27:42 +08:00
Zexi Li
6419d39f87 Merge pull request #5872 from rainzm/feat/eip_autoDellocate
feat(region): Add 'EipAutoDellocate' option when creating vm
2020-04-21 10:26:58 +08:00
Zexi Li
6578038158 Merge pull request #5877 from swordqiu/hotfix/qj-rip-gpu-adjust-scope
fix: adjust scope of isolated_device and reservedips
2020-04-21 10:24:49 +08:00
Qiu Jian
1c78817aba fix: adjust scope of isolated_device and reservedips 2020-04-21 00:36:55 +08:00
Qiu Jian
e0fc57bea1 fix: cloudaccount is created as system shared by default 2020-04-20 22:42:17 +08:00
Rain
7271544618 feat(region): Add 'EipAutoDellocate' option when creating vm
This option specify whether the eip created with vm will be released when deleting vm.
2020-04-20 21:53:26 +08:00
Zexi Li
a0f1bd0c3a Merge pull request #5856 from ioito/hotfix/qx-err-show
fix: show sql connection error
2020-04-20 20:55:13 +08:00
Zexi Li
1e78dfb21b Merge pull request #5854 from rainzm/fix/snapshotpolicy_display
fix(region): Add CustomizeListFilter for snapshotpolicy
2020-04-20 20:54:28 +08:00
Zexi Li
a63757d343 Merge pull request #5870 from rainzm/fix/auto_scaling5
fix(region): Fix problems for Auto Scaling
2020-04-20 20:53:29 +08:00
Zexi Li
4d772ef4d7 Merge pull request #5863 from zhaoxiangchun/bugfix/zxc-monitor-mail
Bugfix/zxc monitor mail
2020-04-20 20:52:56 +08:00
Zexi Li
de7c9c48a7 Merge pull request #5865 from tb365/bugfix/tb-bugfix-0420
lblis & lbbg & lbr & lbb create add fetch owner id
2020-04-20 20:50:47 +08:00
zhaoxiangchun
6c3daec4ce 优化邮件格式
1.邮件主题中的报警级别和web页面进行对应
2.向onecloud发送邮件时,通过html/template进行格式化
2020-04-20 20:34:52 +08:00
Rain
7d52e5de80 fix(region): Fix problems for Auto Scaling
1. 支持 scaling group 根据 enable 过滤
2. 周期策略返回开始时间
3. scaling controller 在创建机器之前先调用 scheduler 的 forcast 接口
4. 修复健康状态检查的一个问题
2020-04-20 19:31:43 +08:00
tangbin
c977fd02ce lblis & lbbg & lbr & lbb create add fetch owner id 2020-04-20 18:51:05 +08:00
Rain
a9b7ca5202 fix(region): Add CustomizeListFilter for snapshotpolicy 2020-04-20 17:33:40 +08:00
Qu Xuan
9cb2727bf1 fix: show sql connection error 2020-04-20 16:47:36 +08:00
1191 changed files with 74662 additions and 31340 deletions

View File

@@ -13,7 +13,7 @@ jobs:
- checkout
- run:
command: |
make check
make -j3 check
build:
requires:
- check
@@ -38,7 +38,7 @@ jobs:
command: |
targets="$(circleci tests glob "cmd/*" | grep -v cmd/host-image | circleci tests split)"
echo $targets | tr ' ' '\n'
make $targets
make -j3 $targets
ls -lh _output/bin/
- save_cache:
key: onecloud-build-cache-{{ checksum "go.mod" }}-{{ checksum "Makefile" }}
@@ -55,6 +55,7 @@ jobs:
environment:
GO111MODULE: "on"
working_directory: /root/go/onecloud
parallelism: 4
steps:
- checkout
- restore_cache:

View File

@@ -36,7 +36,7 @@ jobs:
make cmd/ansibleserver cmd/cloudnet cmd/notify
make cmd/host-deployer && ./scripts/bundle_libraries.sh _output/bin/bundles/host-deployer _output/bin/host-deployer
make cmd/baremetal-agent && ./scripts/bundle_libraries.sh _output/bin/bundles/baremetal-agent _output/bin/baremetal-agent
make cmd/cloudevent cmd/devtool
make cmd/cloudevent cmd/devtool cmd/cloudid
make cmd/*cli
make cmd/esxi-agent
make docker-alpine-build F='-j4 cmd/host cmd/vpcagent cmd/region-dns'
@@ -211,6 +211,16 @@ jobs:
snapshot: true
dockerfile: build/docker/Dockerfile.cloudevent
- name: Image cloudid
uses: elgohr/Publish-Docker-Github-Action@master
with:
name: registry.cn-beijing.aliyuncs.com/yunionio/cloudid
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
registry: registry.cn-beijing.aliyuncs.com
snapshot: true
dockerfile: build/docker/Dockerfile.cloudid
- name: Image devtool
uses: elgohr/Publish-Docker-Github-Action@master
with:

2
.gitignore vendored
View File

@@ -35,3 +35,5 @@ GPATH
GRTAGS
GTAGS
pkg/generated
*.orig

View File

@@ -163,9 +163,15 @@ goimports-check:
fi
.PHONY: goimports-check
vet-check:
./scripts/vet.sh gen
./scripts/vet.sh chk
.PHONY: vet-check
check: fmt-check
check: gendocgo-check
check: goimports-check
check: vet-check
.PHONY: check

View File

@@ -1,7 +1,7 @@
# Yunion OneCloud
[![CircleCI](https://circleci.com/gh/yunionio/onecloud.svg?style=svg)](https://circleci.com/gh/yunionio/onecloud)
[![Build Status](https://travis-ci.com/yunionio/onecloud.svg?branch=master)](https://travis-ci.org/yunionio/onecloud)
[![Build Status](https://travis-ci.com/yunionio/onecloud.svg?branch=master)](https://travis-ci.com/yunionio/onecloud/branches)
[![Go Report Card](https://goreportcard.com/badge/github.com/yunionio/onecloud)](https://goreportcard.com/report/github.com/yunionio/onecloud)
### [README in Chinese](./README-CN.md)
@@ -40,7 +40,7 @@ Please refers to [install & deployment](https://docs.yunion.io/docs/setup/) (cur
- [Yunion OneCloud Documents](https://docs.yunion.io/)
- [Swagger API](https://docs.yunion.cn/api/)
- [Swagger API](https://docs.yunion.cn/apiv2/)
## Architecture

1
build/cloudid/vars Normal file
View File

@@ -0,0 +1 @@
DESCRIPTION="Yunion CloudId"

View File

@@ -3,9 +3,10 @@ FROM alpine:3.11.6
MAINTAINER "Yousong Zhou <zhouyousong@yunionyun.com>"
# openssh-client, for ansible ssh connection
# git, ca-certificates, for fetching ansible roles
RUN set -x \
&& apk update \
&& apk add openssh-client \
&& apk add ansible \
&& apk add tzdata ca-certificates \
&& apk add tzdata git ca-certificates \
&& rm -rf /var/cache/apk/*

View File

@@ -0,0 +1,3 @@
FROM registry.cn-beijing.aliyuncs.com/yunionio/onecloud-base:v0.1
ADD ./_output/bin/cloudid /opt/yunion/bin/cloudid

View File

@@ -1,4 +1,4 @@
FROM registry.cn-beijing.aliyuncs.com/yunionio/host-base:v0.1.0
FROM registry.cn-beijing.aliyuncs.com/yunionio/host-base:v0.2.0
MAINTAINER "Yaoqi Wan wanyaoqi@yunionyun.com"

View File

@@ -1,4 +1,4 @@
FROM registry.cn-beijing.aliyuncs.com/yunionio/openvswitch:2.9.6-1
FROM registry.cn-beijing.aliyuncs.com/yunionio/openvswitch:2.10.4-0
MAINTAINER "Yousong Zhou <zhouyousong@yunion.cn>"

View File

@@ -43,14 +43,14 @@
<table style="padding: 20px 10px; width: 100%;">
<tr>
<td style="padding-bottom: 20px;">
亲爱的{{.name}},您好:
尊敬的{{.name}},您好:
</td>
</tr>
<tr>
<td style="padding-bottom: 10px;">请点击下面的链接,完成用户邮箱的激活:</td>
</tr>
<tr>
<td style="padding-bottom: 30px;"><a href="{{.link}}">{{.link}}</a></td>
<td style="padding-bottom: 30px;"><a href="{{.link}}">{{.link}}</a></td>
</tr>
</table>
</td>

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package main
package entry
import (
"context"
@@ -32,10 +32,6 @@ import (
"yunion.io/x/onecloud/cmd/climc/promputils"
"yunion.io/x/onecloud/cmd/climc/shell"
_ "yunion.io/x/onecloud/cmd/climc/shell/cloudnet"
_ "yunion.io/x/onecloud/cmd/climc/shell/etcd"
_ "yunion.io/x/onecloud/cmd/climc/shell/k8s"
_ "yunion.io/x/onecloud/cmd/climc/shell/monitor"
"yunion.io/x/onecloud/pkg/mcclient"
)
@@ -49,7 +45,7 @@ type BaseOptions struct {
CertFile string `default:"$YUNION_CERT_FILE" help:"certificate file"`
KeyFile string `default:"$YUNION_KEY_FILE" help:"private key file"`
Completion string `default:"" help:"Generate climc auto complete script" choices:"bash"`
Completion string `default:"" help:"Generate climc auto complete script" choices:"bash|zsh"`
UseCachedToken bool `default:"$YUNION_USE_CACHED_TOKEN|false" help:"Use cached token"`
OsUsername string `default:"$OS_USERNAME" help:"Username, defaults to env[OS_USERNAME]"`
@@ -62,6 +58,8 @@ type BaseOptions struct {
OsAccessKey string `default:"$OS_ACCESS_KEY" help:"ak/sk access key, defaults to env[OS_ACCESS_KEY]"`
OsSecretKey string `default:"$OS_SECRET_KEY" help:"ak/s secret, defaults to env[OS_SECRET_KEY]"`
OsAuthToken string `default:"$OS_AUTH_TOKEN" help:"token authenticate, defaults to env[OS_AUTH_TOKEN]"`
OsAuthURL string `default:"$OS_AUTH_URL" help:"Defaults to env[OS_AUTH_URL]"`
OsRegionName string `default:"$OS_REGION_NAME" help:"Defaults to env[OS_REGION_NAME]"`
@@ -73,9 +71,13 @@ type BaseOptions struct {
}
func getSubcommandsParser() (*structarg.ArgumentParser, error) {
var (
prog = "climc"
desc = `Command-line interface to the API server.`
)
parse, e := structarg.NewArgumentParser(&BaseOptions{},
"climc",
`Command-line interface to the API server.`,
prog,
desc,
`See "climc help COMMAND" for help on a specific command.`)
if e != nil {
return nil, e
@@ -96,26 +98,28 @@ func getSubcommandsParser() (*structarg.ArgumentParser, error) {
return nil
}
})
promptRootCmd := promputils.InitRootCmd(prog, desc, parse.GetOptArgs(), parse.GetPosArgs())
for _, v := range shell.CommandTable {
_par, e := subcmd.AddSubParser(v.Options, v.Command, v.Desc, v.Callback)
if e != nil {
return nil, e
}
promputils.AppendCommand(v.Command, v.Desc)
promputils.AppendCommand(promptRootCmd, v.Command, v.Desc)
cmd := v.Command
for _, v := range _par.GetOptArgs() {
text := v.String()
text = strings.TrimLeft(text, "[<")
text = strings.TrimRight(text, "]>")
promputils.AppendOpt(cmd, text, v.HelpString(""))
promputils.AppendOpt(cmd, text, v.HelpString(""), v)
}
for _, v := range _par.GetPosArgs() {
text := v.String()
text = strings.TrimLeft(text, "[<")
text = strings.TrimRight(text, "]>")
promputils.AppendPos(cmd, text, v.HelpString(""))
promputils.AppendPos(cmd, text, v.HelpString(""), v)
}
}
return parse, nil
@@ -131,8 +135,8 @@ func newClientSession(options *BaseOptions) (*mcclient.ClientSession, error) {
if len(options.OsAuthURL) == 0 {
return nil, fmt.Errorf("Missing OS_AUTH_URL")
}
if len(options.OsUsername) == 0 && len(options.OsAccessKey) == 0 {
return nil, fmt.Errorf("Missing OS_USERNAME or OS_ACCESS_KEY")
if len(options.OsUsername) == 0 && len(options.OsAccessKey) == 0 && len(options.OsAuthToken) == 0 {
return nil, fmt.Errorf("Missing OS_USERNAME or OS_ACCESS_KEY or OS_AUTH_TOKEN")
}
if len(options.OsUsername) > 0 && len(options.OsPassword) == 0 {
return nil, fmt.Errorf("Missing OS_PASSWORD")
@@ -140,9 +144,6 @@ func newClientSession(options *BaseOptions) (*mcclient.ClientSession, error) {
if len(options.OsAccessKey) > 0 && len(options.OsSecretKey) == 0 {
return nil, fmt.Errorf("Missing OS_SECRET_KEY")
}
if len(options.OsRegionName) == 0 {
return nil, fmt.Errorf("Missing OS_REGION_NAME")
}
logLevel := "info"
if options.Debug {
@@ -185,7 +186,11 @@ func newClientSession(options *BaseOptions) (*mcclient.ClientSession, error) {
if cacheToken == nil {
var token mcclient.TokenCredential
var err error
if len(options.OsAccessKey) > 0 {
if len(options.OsAuthToken) > 0 {
token, err = client.AuthenticateToken(options.OsAuthToken, options.OsProjectName,
options.OsProjectDomain,
mcclient.AuthSourceCli)
} else if len(options.OsAccessKey) > 0 {
token, err = client.AuthenticateByAccessKey(options.OsAccessKey,
options.OsSecretKey, mcclient.AuthSourceCli)
} else {
@@ -261,7 +266,7 @@ func executeSubcommand(
}
}
func main() {
func ClimcMain() {
parser, e := getSubcommandsParser()
if e != nil {
showErrorAndExit(e)
@@ -270,7 +275,7 @@ func main() {
options := parser.Options().(*BaseOptions)
if len(options.Completion) > 0 {
completeScript := promputils.GenerateAutoCompleteCmds(options.Completion)
completeScript := promputils.GenerateAutoCompleteCmds(promputils.GetRootCmd(), options.Completion)
if len(completeScript) > 0 {
fmt.Printf("%s", completeScript)
}

15
cmd/climc/entry/doc.go Normal file
View File

@@ -0,0 +1,15 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package entry // import "yunion.io/x/onecloud/cmd/climc/entry"

42
cmd/climc/main.go Normal file
View File

@@ -0,0 +1,42 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package main
import (
"yunion.io/x/onecloud/cmd/climc/entry"
_ "yunion.io/x/onecloud/cmd/climc/shell"
_ "yunion.io/x/onecloud/cmd/climc/shell/ansible"
_ "yunion.io/x/onecloud/cmd/climc/shell/cloudevent"
_ "yunion.io/x/onecloud/cmd/climc/shell/cloudid"
_ "yunion.io/x/onecloud/cmd/climc/shell/cloudnet"
_ "yunion.io/x/onecloud/cmd/climc/shell/compute"
_ "yunion.io/x/onecloud/cmd/climc/shell/etcd"
_ "yunion.io/x/onecloud/cmd/climc/shell/events"
_ "yunion.io/x/onecloud/cmd/climc/shell/identity"
_ "yunion.io/x/onecloud/cmd/climc/shell/image"
_ "yunion.io/x/onecloud/cmd/climc/shell/itsm"
_ "yunion.io/x/onecloud/cmd/climc/shell/k8s"
_ "yunion.io/x/onecloud/cmd/climc/shell/logger"
_ "yunion.io/x/onecloud/cmd/climc/shell/meter"
_ "yunion.io/x/onecloud/cmd/climc/shell/misc"
_ "yunion.io/x/onecloud/cmd/climc/shell/monitor"
_ "yunion.io/x/onecloud/cmd/climc/shell/notify"
_ "yunion.io/x/onecloud/cmd/climc/shell/servicetree"
_ "yunion.io/x/onecloud/cmd/climc/shell/yunionconf"
)
func main() {
entry.ClimcMain()
}

View File

@@ -0,0 +1,178 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package promputils
import (
"fmt"
"io"
"strings"
"text/template"
"yunion.io/x/structarg"
)
// ref: https://github.com/spf13/cobra/blob/master/zsh_completions.go
var (
zshCompFuncMap = template.FuncMap{
"genZshFuncName": zshCompGenFuncName,
"extractFlags": zshCompExtractFlag,
"genFlagEntryForZshArguments": zshCompGenFlagEntryForArguments,
"extractArgsCompletions": zshCompExtractArgumentCompletionHintsForRendering,
}
zshCompletionText = `
{{/* should accept Command (that contains subcommands) as parameter */}}
{{define "argumentsC" -}}
{{ $cmdPath := genZshFuncName .}}
function {{$cmdPath}} {
local -a commands
_arguments -C \{{- range extractFlags .}}
{{genFlagEntryForZshArguments .}} \{{- end}}
"1: :->cmnds" \
"*::arg:->args"
case $state in
cmnds)
commands=({{range .SubCmds}}
"{{.Name}}:{{.Desc}}"{{end}}
)
_describe "command" commands
;;
esac
case "$words[1]" in {{- range .SubCmds}}
{{.Name}})
{{$cmdPath}}_{{.Name}}
;;{{end}}
esac
}
{{range .SubCmds}}
{{template "selectCmdTemplate" .}}
{{- end}}
{{- end}}
{{/* should accept Command without subcommands as parameter */}}
{{define "arguments" -}}
function {{genZshFuncName .}} {
{{" _arguments"}}{{range extractFlags .}} \
{{genFlagEntryForZshArguments . -}}
{{end}}{{range extractArgsCompletions .}} \
{{.}}{{end}}
}
{{end}}
{{/* dispatcher for commands with or without subcommands */}}
{{define "selectCmdTemplate" -}}
{{if .SubCmds}}{{template "argumentsC" .}}{{else}}{{template "arguments" .}}{{end}}
{{- end}}
{{/* template entry point */}}
{{define "Main" -}}
#compdef _{{.Name}} {{.Name}}
{{template "selectCmdTemplate" .}}
compdef _{{.Name}} {{.Name}}
{{end}}
`
)
func zshCompGenFuncName(c *Cmd) string {
if c.ParentCmd != nil {
return zshCompGenFuncName(c.ParentCmd) + "_" + c.Name
}
return "_" + c.Name
}
func zshCompExtractFlag(c *Cmd) []structarg.Argument {
return c.GetArguments()
}
func zshCompGenFlagEntryForArguments(f structarg.Argument) string {
// not process positional argument and single command
if f.IsPositional() {
return ""
}
if f.ShortToken() == "" {
return zshCompGenFlagEntryForSingleOptionFlag(f)
}
return zshCompGenFlagEntryForMultiOptionFlag(f)
}
func zshCompGenFlagEntryForSingleOptionFlag(f structarg.Argument) string {
var option, multiMark, extras string
if f.IsMulti() {
multiMark = "*"
}
option = "--" + f.Token()
extras = zshCompGenFlagEntryExtras(f)
return fmt.Sprintf(`'%s%s[%s]%s'`, multiMark, option, zshCompQuoteFlagDescription(f.HelpString("")), extras)
}
func zshCompGenFlagEntryForMultiOptionFlag(f structarg.Argument) string {
var options, parenMultiMark, curlyMultiMark, extras string
if f.IsMulti() {
parenMultiMark = "*"
curlyMultiMark = "\\*"
}
options = fmt.Sprintf(`'(%s-%s %s--%s)'{%s-%s,%s--%s}`,
parenMultiMark, f.ShortToken(), parenMultiMark, f.Token(), curlyMultiMark, f.ShortToken(), curlyMultiMark, f.Token())
extras = zshCompGenFlagEntryExtras(f)
return fmt.Sprintf(`%s'[%s]%s'`, options, zshCompQuoteFlagDescription(f.HelpString("")), extras)
}
func zshCompGenFlagEntryExtras(f structarg.Argument) string {
if !f.NeedData() {
return ""
}
// allow options for flag
extras := ":"
type iChoices interface {
Choices() []string
}
if hasChoices, ok := f.(iChoices); ok {
// process choices
var words []string
for _, w := range hasChoices.Choices() {
words = append(words, fmt.Sprintf("%q", w))
}
if len(words) != 0 {
extras = fmt.Sprintf("%s :(%s)", extras, strings.Join(words, " "))
}
}
return extras
}
func zshCompQuoteFlagDescription(s string) string {
s = strings.Replace(s, "'", `'\''`, -1)
s = strings.Replace(s, "[", `\[`, -1)
s = strings.Replace(s, "]", `\]`, -1)
return s
}
func zshCompExtractArgumentCompletionHintsForRendering(c *Cmd) []string {
return nil
}
func (c *Cmd) GenZshCompletion(w io.Writer) error {
tmpl, err := template.New("Main").Funcs(zshCompFuncMap).Parse(zshCompletionText)
if err != nil {
return fmt.Errorf("error creating zsh completion template: %v", err)
}
return tmpl.Execute(w, c.Root())
}

View File

@@ -75,33 +75,3 @@ _climc(){
do
line="${arr[$i]}"
allopts[count]=${line%s`
const ZSH_COMPLETE_SCRIPT_2 = `%"#"*}
subopts[count]=${line#*"#"}
((count++))
done
_arguments \
'1: :->commands'\
'*: :->options'
case $state in
commands)
_arguments '1:Comm:(${allopts[*]})'
;;
*)
item=1
for key in ${allopts[*]}
do
case $words[2] in
$key)
compadd "$@"` + "`echo $subopts[item]`" + `
;;
*)
;;
esac
((item++))
done
esac
}
_climc "$@"
`

View File

@@ -15,26 +15,118 @@
package promputils
import (
"bytes"
"fmt"
"regexp"
"strings"
prompt "github.com/c-bata/go-prompt"
"yunion.io/x/structarg"
)
type Cmd struct {
desc string
optArgs []prompt.Suggest
posArgs []prompt.Suggest
}
var cmds = make(map[string]*Cmd)
var (
subcmds = make(map[string]*Cmd)
rootCmd *Cmd
)
var optionHelp = []prompt.Suggest{
{Text: "-h"},
{Text: "--help"},
}
type Cmd struct {
Name string
Desc string
optArgs []CmdArgument
posArgs []CmdArgument
ParentCmd *Cmd
SubCmds []*Cmd
}
func InitRootCmd(name, desc string, optArgs, posArgs []structarg.Argument) *Cmd {
rootCmd = NewCmd(name, desc)
for _, optA := range optArgs {
rootCmd.AddOptArgument(optA, optA.Token(), optA.HelpString(""))
}
for _, posA := range posArgs {
rootCmd.AddPosArgument(posA, posA.Token(), posA.HelpString(""))
}
return rootCmd
}
func GetRootCmd() *Cmd {
return rootCmd
}
func NewCmd(name, desc string) *Cmd {
return &Cmd{
Name: name,
Desc: desc,
optArgs: make([]CmdArgument, 0),
posArgs: make([]CmdArgument, 0),
SubCmds: make([]*Cmd, 0),
}
}
func (c Cmd) getPromptSuggests(args []CmdArgument) []prompt.Suggest {
ret := make([]prompt.Suggest, 0)
for _, arg := range args {
ret = append(ret, arg.Suggest)
}
return ret
}
func (c *Cmd) Root() *Cmd {
if c.ParentCmd == nil {
return c
}
return c.ParentCmd.Root()
}
func (c Cmd) GetName() string {
return c.Name
}
func (c *Cmd) AddCmd(cmd *Cmd) {
c.SubCmds = append(c.SubCmds, cmd)
}
func (c Cmd) GetPromptOptSuggests() []prompt.Suggest {
return c.getPromptSuggests(c.optArgs)
}
func (c Cmd) GetPromptPosSuggests() []prompt.Suggest {
return c.getPromptSuggests(c.posArgs)
}
func (c Cmd) GetOptArguments() []structarg.Argument {
return c.getArguments(c.optArgs)
}
func (c Cmd) GetArguments() []structarg.Argument {
ret := c.GetOptArguments()
ret = append(ret, c.GetPosArguments()...)
return ret
}
func (c Cmd) GetPosArguments() []structarg.Argument {
return c.getArguments(c.posArgs)
}
func (c Cmd) getArguments(args []CmdArgument) []structarg.Argument {
ret := make([]structarg.Argument, 0)
for _, a := range args {
ret = append(ret, a.Argument)
}
return ret
}
type CmdArgument struct {
Suggest prompt.Suggest
Argument structarg.Argument
}
func optionCompleter(args []string, long bool) []prompt.Suggest {
l := len(args)
if l == 0 {
@@ -47,11 +139,11 @@ func optionCompleter(args []string, long bool) []prompt.Suggest {
return optionHelp
}
if cmds[args[0]] == nil {
if subcmds[args[0]] == nil {
return []prompt.Suggest{}
}
_cmd := cmds[args[0]].optArgs
_cmd := subcmds[args[0]].GetPromptOptSuggests()
return prompt.FilterContains(_cmd, strings.TrimLeft(args[l-1], "-"), true)
}
@@ -100,7 +192,7 @@ func argumentsCompleter(args []string) []prompt.Suggest {
if len(args) == 1 {
return prompt.FilterHasPrefix(commands, args[0], true)
}
_cmd, ok := cmds[args[0]]
_cmd, ok := subcmds[args[0]]
if !ok {
return []prompt.Suggest{}
}
@@ -111,48 +203,75 @@ func argumentsCompleter(args []string) []prompt.Suggest {
prm := _cmd.posArgs[len(args)-2]
subcommands := []prompt.Suggest{
prm,
prm.Suggest,
}
return prompt.FilterHasPrefix(subcommands, args[len(args)-1], true)
}
func AppendCommand(text, desc string) {
func AppendCommand(parentCmd *Cmd, text, desc string) {
commands = append(commands, prompt.Suggest{Text: text, Description: desc})
cmds[text] = &Cmd{}
cmds[text].desc = desc
cmds[text].posArgs = []prompt.Suggest{}
cmds[text].optArgs = []prompt.Suggest{}
cmd := &Cmd{
Name: text,
Desc: desc,
posArgs: make([]CmdArgument, 0),
optArgs: make([]CmdArgument, 0),
ParentCmd: parentCmd,
}
subcmds[text] = cmd
parentCmd.AddCmd(cmd)
}
func AppendPos(text, cmd, desc string) {
var v = []prompt.Suggest{{Text: cmd, Description: desc}}
cmds[text].posArgs = append(cmds[text].posArgs, v...)
func (c *Cmd) addArgument(target *[]CmdArgument, arg structarg.Argument, argStr string, desc string) {
*target = append(*target, CmdArgument{
Suggest: prompt.Suggest{
Text: argStr,
Description: desc,
},
Argument: arg,
})
}
func AppendOpt(text, cmd, desc string) {
var v = []prompt.Suggest{{Text: cmd, Description: desc}}
cmds[text].optArgs = append(cmds[text].optArgs, v...)
func (c *Cmd) AddPosArgument(arg structarg.Argument, argStr string, desc string) {
c.addArgument(&c.posArgs, arg, argStr, desc)
}
func GenerateAutoCompleteCmds(shell string) string {
func (c *Cmd) AddOptArgument(arg structarg.Argument, argStr string, desc string) {
c.addArgument(&c.optArgs, arg, argStr, desc)
}
func AppendPos(text, cmd, desc string, arg structarg.Argument) {
cmdObj := subcmds[text]
cmdObj.AddPosArgument(arg, cmd, desc)
}
func AppendOpt(text, cmd, desc string, arg structarg.Argument) {
cmdObj := subcmds[text]
cmdObj.AddOptArgument(arg, cmd, desc)
}
func GenerateAutoCompleteCmds(rootCmd *Cmd, shell string) string {
var ret = []string{}
var i = 0
if strings.ToLower(shell) == "zsh" {
i = 1
out := bytes.NewBufferString("")
if err := rootCmd.GenZshCompletion(out); err != nil {
panic(err)
}
return out.String()
}
for cmd, options := range cmds {
for _, cmd := range subcmds {
var (
strPosArgs = []string{}
strOptArgs = []string{}
)
for _, posArg := range options.posArgs {
for _, posArg := range cmd.GetPromptPosSuggests() {
strPosArgs = append(strPosArgs, posArg.Text)
}
for _, optArg := range options.optArgs {
for _, optArg := range cmd.GetPromptOptSuggests() {
strOptArgs = append(strOptArgs, strings.Split(optArg.Text, " ")[0])
}
ret = append(ret, fmt.Sprintf(`arr[%d]="%s# %s %s"`, i, cmd,
ret = append(ret, fmt.Sprintf(`arr[%d]="%s# %s %s"`, i, cmd.Name,
strings.Join(strPosArgs, " "), strings.Join(strOptArgs, " ")))
i += 1
}

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package ansible
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package ansible
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package ansible
import (
"yunion.io/x/onecloud/pkg/mcclient"
@@ -49,4 +49,34 @@ func init() {
printList(apbs, modules.AnsiblePlaybooksV2.GetColumns(s))
return nil
})
R(&AnsiblePlaybookV2IdOptions{}, "ansibleplaybookv2-run", "Run ansible playbook",
func(s *mcclient.ClientSession, opts *AnsiblePlaybookV2IdOptions) error {
apb, err := modules.AnsiblePlaybooksV2.PerformAction(s, opts.ID, "run", nil)
if err != nil {
return err
}
printObject(apb)
return nil
},
)
R(&AnsiblePlaybookV2IdOptions{}, "ansibleplaybookv2-stop", "Stop ansible playbook",
func(s *mcclient.ClientSession, opts *AnsiblePlaybookV2IdOptions) error {
apb, err := modules.AnsiblePlaybooksV2.PerformAction(s, opts.ID, "stop", nil)
if err != nil {
return err
}
printObject(apb)
return nil
},
)
R(&AnsiblePlaybookV2IdOptions{}, "ansibleplaybookv2-delete", "Delete ansible playbook",
func(s *mcclient.ClientSession, opts *AnsiblePlaybookV2IdOptions) error {
apb, err := modules.AnsiblePlaybooksV2.Delete(s, opts.ID, nil)
if err != nil {
return err
}
printObject(apb)
return nil
},
)
}

View File

@@ -0,0 +1,32 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package ansible
import (
"yunion.io/x/onecloud/cmd/climc/shell"
"yunion.io/x/onecloud/pkg/util/printutils"
)
var (
R = shell.R
printList = printutils.PrintJSONList
printObject = printutils.PrintJSONObject
printBatchResults = printutils.PrintJSONBatchResults
InvalidUpdateError = shell.InvalidUpdateError
printObjectRecursive = printutils.PrintJSONObjectRecursive
exportList = shell.ExportList
)

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package ansible
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package ansible
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package cloudevent
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -0,0 +1,25 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudevent
import (
"yunion.io/x/onecloud/cmd/climc/shell"
"yunion.io/x/onecloud/pkg/util/printutils"
)
var (
R = shell.R
printList = printutils.PrintJSONList
)

View File

@@ -0,0 +1,168 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudid
import (
"yunion.io/x/jsonutils"
"yunion.io/x/onecloud/pkg/mcclient"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
)
func init() {
type CloudgroupListOptions struct {
options.BaseListOptions
ClouduserId string `json:"clouduser_id"`
CloudpolicyId string `json:"cloudpolicy_id"`
Usable bool `json:"usable"`
}
R(&CloudgroupListOptions{}, "cloud-group-list", "List cloud groups", func(s *mcclient.ClientSession, opts *CloudgroupListOptions) error {
params, err := options.ListStructToParams(opts)
if err != nil {
return err
}
result, err := modules.Cloudgroups.List(s, params)
if err != nil {
return err
}
printList(result, modules.Cloudgroups.GetColumns(s))
return nil
})
type CloudgroupCreateOptions struct {
NAME string `json:"name"`
PROVIDER string `json:"provider" choices:"Google|Aliyun|Aws|Huawei|Qcloud"`
CloudpolicyIds []string `json:"cloudpolicy_ids"`
Desc string `json:"description"`
}
R(&CloudgroupCreateOptions{}, "cloud-group-create", "Create cloud group", func(s *mcclient.ClientSession, opts *CloudgroupCreateOptions) error {
params := jsonutils.Marshal(opts)
result, err := modules.Cloudgroups.Create(s, params)
if err != nil {
return err
}
printObject(result)
return nil
})
type CloudgroupIdOptions struct {
ID string `help:"Cloudgroup Id"`
}
R(&CloudgroupIdOptions{}, "cloud-group-delete", "Delete cloud group", func(s *mcclient.ClientSession, opts *CloudgroupIdOptions) error {
result, err := modules.Cloudgroups.Delete(s, opts.ID, nil)
if err != nil {
return err
}
printObject(result)
return nil
})
R(&CloudgroupIdOptions{}, "cloud-group-show", "Show cloud group", func(s *mcclient.ClientSession, opts *CloudgroupIdOptions) error {
result, err := modules.Cloudgroups.Get(s, opts.ID, nil)
if err != nil {
return err
}
printObject(result)
return nil
})
R(&CloudgroupIdOptions{}, "cloud-group-syncstatus", "Sync cloud group status", func(s *mcclient.ClientSession, opts *CloudgroupIdOptions) error {
result, err := modules.Cloudgroups.PerformAction(s, opts.ID, "syncstatus", nil)
if err != nil {
return err
}
printObject(result)
return nil
})
type CloudgroupPolicyOptions struct {
ID string `help:"Cloudgroup Id"`
CLOUDPOLICY_ID string `help:"Cloudpolicy Id"`
}
R(&CloudgroupPolicyOptions{}, "cloud-group-attach-policy", "Attach policy for cloud group", func(s *mcclient.ClientSession, opts *CloudgroupPolicyOptions) error {
result, err := modules.Cloudgroups.PerformAction(s, opts.ID, "attach-policy", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
R(&CloudgroupPolicyOptions{}, "cloud-group-detach-policy", "Detach policy from cloud group", func(s *mcclient.ClientSession, opts *CloudgroupPolicyOptions) error {
result, err := modules.Cloudgroups.PerformAction(s, opts.ID, "detach-policy", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
type CloudgroupUserOptions struct {
ID string `help:"Cloudgroup Id"`
CLOUDUSER_ID string `help:"Clouduser Id"`
}
R(&CloudgroupUserOptions{}, "cloud-group-add-user", "Add user to cloud group", func(s *mcclient.ClientSession, opts *CloudgroupUserOptions) error {
result, err := modules.Cloudgroups.PerformAction(s, opts.ID, "add-user", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
R(&CloudgroupUserOptions{}, "cloud-group-remove-user", "Remove user from cloud group", func(s *mcclient.ClientSession, opts *CloudgroupUserOptions) error {
result, err := modules.Cloudgroups.PerformAction(s, opts.ID, "remove-user", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
type CloudgroupPoliciesOptions struct {
ID string `help:"Cloudgroup Id"`
CloudpolicyIds []string `json:"cloudpolicy_ids"`
}
R(&CloudgroupPoliciesOptions{}, "cloud-group-set-policies", "Set cloudpolicies for cloud group", func(s *mcclient.ClientSession, opts *CloudgroupPoliciesOptions) error {
result, err := modules.Cloudgroups.PerformAction(s, opts.ID, "set-policies", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
type CloudgroupUsersOptions struct {
ID string `help:"Cloudgroup Id"`
ClouduserIds []string `json:"clouduser_ids"`
}
R(&CloudgroupUsersOptions{}, "cloud-group-set-users", "Set users for cloud group", func(s *mcclient.ClientSession, opts *CloudgroupUsersOptions) error {
result, err := modules.Cloudgroups.PerformAction(s, opts.ID, "set-users", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
}

View File

@@ -0,0 +1,73 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudid
import (
"yunion.io/x/onecloud/pkg/mcclient"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
)
func init() {
type CloudgroupcacheListOptions struct {
options.BaseListOptions
CloudgroupId string `json:"cloudgroup_id"`
}
R(&CloudgroupcacheListOptions{}, "cloud-group-cache-list", "List cloud group caches", func(s *mcclient.ClientSession, opts *CloudgroupcacheListOptions) error {
params, err := options.ListStructToParams(opts)
if err != nil {
return err
}
result, err := modules.Cloudgroupcaches.List(s, params)
if err != nil {
return err
}
printList(result, modules.Cloudgroupcaches.GetColumns(s))
return nil
})
type CloudgroupcacheIdOption struct {
ID string `help:"Cloudgroup Id"`
}
R(&CloudgroupcacheIdOption{}, "cloud-group-cache-show", "Show cloud groupcache details", func(s *mcclient.ClientSession, opts *CloudgroupcacheIdOption) error {
result, err := modules.Cloudgroupcaches.Get(s, opts.ID, nil)
if err != nil {
return err
}
printObject(result)
return nil
})
R(&CloudgroupcacheIdOption{}, "cloud-group-cache-syncstatus", "Sync cloudgroupcache", func(s *mcclient.ClientSession, opts *CloudgroupcacheIdOption) error {
result, err := modules.Cloudgroupcaches.PerformAction(s, opts.ID, "syncstatus", nil)
if err != nil {
return err
}
printObject(result)
return nil
})
R(&CloudgroupcacheIdOption{}, "cloud-group-cache-delete", "Delete cloudgroupcache", func(s *mcclient.ClientSession, opts *CloudgroupcacheIdOption) error {
result, err := modules.Cloudgroupcaches.Delete(s, opts.ID, nil)
if err != nil {
return err
}
printObject(result)
return nil
})
}

View File

@@ -0,0 +1,72 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudid
import (
"yunion.io/x/jsonutils"
"yunion.io/x/onecloud/pkg/mcclient"
"yunion.io/x/onecloud/pkg/mcclient/modulebase"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
)
func init() {
type CloudgroupPolicyListOptions struct {
options.BaseListOptions
Cloudgroup string `help:"ID or Name of Cloudgroup"`
Cloudpolicy string `help:"Policy ID or name"`
}
R(&CloudgroupPolicyListOptions{}, "cloud-group-policy-list", "List cloudgroup cloudpolicy pairs", func(s *mcclient.ClientSession, args *CloudgroupPolicyListOptions) error {
var params *jsonutils.JSONDict
{
var err error
params, err = args.BaseListOptions.Params()
if err != nil {
return err
}
}
var result *modulebase.ListResult
var err error
if len(args.Cloudgroup) > 0 {
result, err = modules.Cloudgrouppolicies.ListDescendent(s, args.Cloudgroup, params)
} else if len(args.Cloudpolicy) > 0 {
result, err = modules.Cloudgrouppolicies.ListDescendent2(s, args.Cloudpolicy, params)
} else {
result, err = modules.Cloudgrouppolicies.List(s, params)
}
if err != nil {
return err
}
printList(result, modules.Cloudgrouppolicies.GetColumns(s))
return nil
})
type CloudgroupPolicyDetailOptions struct {
CLOUDUSER string `help:"ID or Name of Cloudgroup"`
CLOUDPOLICY string `help:"ID or Name of Cloudpolicy"`
}
R(&CloudgroupPolicyDetailOptions{}, "cloud-group-policy-show", "Show cloudgrouppolicy details", func(s *mcclient.ClientSession, args *CloudgroupPolicyDetailOptions) error {
query := jsonutils.NewDict()
result, err := modules.Cloudgrouppolicies.Get(s, args.CLOUDUSER, args.CLOUDPOLICY, query)
if err != nil {
return err
}
printObject(result)
return nil
})
}

View File

@@ -0,0 +1,72 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudid
import (
"yunion.io/x/jsonutils"
"yunion.io/x/onecloud/pkg/mcclient"
"yunion.io/x/onecloud/pkg/mcclient/modulebase"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
)
func init() {
type CloudgroupUserListOptions struct {
options.BaseListOptions
Cloudgroup string `help:"ID or Name of Cloudgroup"`
Clouduser string `help:"User ID or name"`
}
R(&CloudgroupUserListOptions{}, "cloud-group-user-list", "List cloudgroup clouduser pairs", func(s *mcclient.ClientSession, args *CloudgroupUserListOptions) error {
var params *jsonutils.JSONDict
{
var err error
params, err = args.BaseListOptions.Params()
if err != nil {
return err
}
}
var result *modulebase.ListResult
var err error
if len(args.Cloudgroup) > 0 {
result, err = modules.Cloudgroupusers.ListDescendent(s, args.Cloudgroup, params)
} else if len(args.Clouduser) > 0 {
result, err = modules.Cloudgroupusers.ListDescendent2(s, args.Clouduser, params)
} else {
result, err = modules.Cloudgroupusers.List(s, params)
}
if err != nil {
return err
}
printList(result, modules.Cloudgroupusers.GetColumns(s))
return nil
})
type CloudgroupUserDetailOptions struct {
CLOUDUSER string `help:"ID or Name of Cloudgroup"`
CLOUDPOLICY string `help:"ID or Name of Clouduser"`
}
R(&CloudgroupUserDetailOptions{}, "cloud-group-user-show", "Show cloudgroupuser details", func(s *mcclient.ClientSession, args *CloudgroupUserDetailOptions) error {
query := jsonutils.NewDict()
result, err := modules.Cloudgroupusers.Get(s, args.CLOUDUSER, args.CLOUDPOLICY, query)
if err != nil {
return err
}
printObject(result)
return nil
})
}

View File

@@ -0,0 +1,81 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudid
import (
"yunion.io/x/jsonutils"
"yunion.io/x/onecloud/pkg/mcclient"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
)
func init() {
type CloudpolicyListOptions struct {
options.BaseListOptions
ClouduserId string `json:"clouduser_id"`
CloudgroupId string `json:"cloudgroup_id"`
}
R(&CloudpolicyListOptions{}, "cloud-policy-list", "List cloud policies", func(s *mcclient.ClientSession, opts *CloudpolicyListOptions) error {
params, err := options.ListStructToParams(opts)
if err != nil {
return err
}
result, err := modules.Cloudpolicies.List(s, params)
if err != nil {
return err
}
printList(result, modules.Cloudpolicies.GetColumns(s))
return nil
})
type CloudpolicyIdOptions struct {
ID string `help:"Cloudpolicy Id"`
}
R(&CloudpolicyIdOptions{}, "cloud-policy-show", "Sow cloud policiy details", func(s *mcclient.ClientSession, opts *CloudpolicyIdOptions) error {
result, err := modules.Cloudpolicies.Get(s, opts.ID, nil)
if err != nil {
return err
}
printObject(result)
return nil
})
type CloudpolicyGroupOptions struct {
ID string `help:"Cloudpolicy Id"`
CLOUDGROUP_ID string `help:"Cloudgroup Id" json:"cloudgroup_id"`
}
R(&CloudpolicyGroupOptions{}, "cloud-policy-assign-group", "Assign cloud policiy to group", func(s *mcclient.ClientSession, opts *CloudpolicyGroupOptions) error {
result, err := modules.Cloudpolicies.PerformAction(s, opts.ID, "assign-group", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
R(&CloudpolicyGroupOptions{}, "cloud-policy-revoke-group", "Revoke cloud policiy from group", func(s *mcclient.ClientSession, opts *CloudpolicyGroupOptions) error {
result, err := modules.Cloudpolicies.PerformAction(s, opts.ID, "revoke-group", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
}

View File

@@ -0,0 +1,72 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudid
import (
"yunion.io/x/jsonutils"
"yunion.io/x/onecloud/pkg/mcclient"
"yunion.io/x/onecloud/pkg/mcclient/modulebase"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
)
func init() {
type ClouduserPolicyListOptions struct {
options.BaseListOptions
Clouduser string `help:"ID or Name of Clouduser"`
Cloudpolicy string `help:"Policy ID or name"`
}
R(&ClouduserPolicyListOptions{}, "cloud-user-policy-list", "List clouduser cloudpolicy pairs", func(s *mcclient.ClientSession, args *ClouduserPolicyListOptions) error {
var params *jsonutils.JSONDict
{
var err error
params, err = args.BaseListOptions.Params()
if err != nil {
return err
}
}
var result *modulebase.ListResult
var err error
if len(args.Clouduser) > 0 {
result, err = modules.Clouduserpolicies.ListDescendent(s, args.Clouduser, params)
} else if len(args.Cloudpolicy) > 0 {
result, err = modules.Clouduserpolicies.ListDescendent2(s, args.Cloudpolicy, params)
} else {
result, err = modules.Clouduserpolicies.List(s, params)
}
if err != nil {
return err
}
printList(result, modules.Clouduserpolicies.GetColumns(s))
return nil
})
type ClouduserPolicyDetailOptions struct {
CLOUDUSER string `help:"ID or Name of Clouduser"`
CLOUDPOLICY string `help:"ID or Name of Cloudpolicy"`
}
R(&ClouduserPolicyDetailOptions{}, "cloud-user-policy-show", "Show clouduserpolicy details", func(s *mcclient.ClientSession, args *ClouduserPolicyDetailOptions) error {
query := jsonutils.NewDict()
result, err := modules.Clouduserpolicies.Get(s, args.CLOUDUSER, args.CLOUDPOLICY, query)
if err != nil {
return err
}
printObject(result)
return nil
})
}

View File

@@ -0,0 +1,197 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudid
import (
"yunion.io/x/jsonutils"
"yunion.io/x/onecloud/pkg/mcclient"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
)
func init() {
type ClouduserListOptions struct {
options.BaseListOptions
CloudaccountId string `help:"Cloudaccount Id"`
CloudproviderId string `help:"Cloudprovider Id"`
CloudpolicyId string `help:"filter cloudusers by cloudpolicy"`
CloudgroupId string `help:"filter cloudusers by cloudgroup"`
}
R(&ClouduserListOptions{}, "cloud-user-list", "List cloud users", func(s *mcclient.ClientSession, opts *ClouduserListOptions) error {
params, err := options.ListStructToParams(opts)
if err != nil {
return err
}
result, err := modules.Cloudusers.List(s, params)
if err != nil {
return err
}
printList(result, modules.Cloudusers.GetColumns(s))
return nil
})
type ClouduserCreateOptions struct {
Name string
CloudaccountId string `help:"Cloudaccount Id"`
CloudproviderId string `help:"Cloudprovider Id"`
OwnerId string `help:"Owner Id"`
CloudpolicyIds []string `help:"cloudpolicy ids"`
CloudgroupIds []string `help:"cloudgroup ids"`
Email string `help:"email address"`
MobilePhone string `help:"phone number"`
IsConsoleLogin *bool `help:"is console login"`
Password string `help:"clouduser password"`
}
R(&ClouduserCreateOptions{}, "cloud-user-create", "Create cloud user", func(s *mcclient.ClientSession, opts *ClouduserCreateOptions) error {
params := jsonutils.Marshal(opts)
result, err := modules.Cloudusers.Create(s, params)
if err != nil {
return err
}
printObject(result)
return nil
})
type ClouduserIdOptions struct {
ID string `help:"Clouduser Id"`
}
R(&ClouduserIdOptions{}, "cloud-user-delete", "Delete cloud user", func(s *mcclient.ClientSession, opts *ClouduserIdOptions) error {
result, err := modules.Cloudusers.Delete(s, opts.ID, nil)
if err != nil {
return err
}
printObject(result)
return nil
})
R(&ClouduserIdOptions{}, "cloud-user-logininfo", "Show cloud user login info", func(s *mcclient.ClientSession, opts *ClouduserIdOptions) error {
result, err := modules.Cloudusers.GetLoginInfo(s, opts.ID, nil)
if err != nil {
return err
}
printObject(result)
return nil
})
R(&ClouduserIdOptions{}, "cloud-user-show", "Show cloud user", func(s *mcclient.ClientSession, opts *ClouduserIdOptions) error {
result, err := modules.Cloudusers.Get(s, opts.ID, nil)
if err != nil {
return err
}
printObject(result)
return nil
})
type ClouduserSyncOptions struct {
ID string `help:"Clouduser Id"`
PolicyOnly bool `help:"Ony sync clouduser policies for cloud"`
}
R(&ClouduserSyncOptions{}, "cloud-user-sync", "Sync cloud user policies", func(s *mcclient.ClientSession, opts *ClouduserSyncOptions) error {
result, err := modules.Cloudusers.PerformAction(s, opts.ID, "sync", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
R(&ClouduserIdOptions{}, "cloud-user-syncstatus", "Sync cloud user status", func(s *mcclient.ClientSession, opts *ClouduserIdOptions) error {
result, err := modules.Cloudusers.PerformAction(s, opts.ID, "syncstatus", nil)
if err != nil {
return err
}
printObject(result)
return nil
})
type ClouduserPolicyOptions struct {
ID string `help:"Clouduser Id"`
CLOUDPOLICY_ID string `help:"cloudpolicy Id"`
}
R(&ClouduserPolicyOptions{}, "cloud-user-attach-policy", "Attach policy for cloud user", func(s *mcclient.ClientSession, opts *ClouduserPolicyOptions) error {
result, err := modules.Cloudusers.PerformAction(s, opts.ID, "attach-policy", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
R(&ClouduserPolicyOptions{}, "cloud-user-detach-policy", "Detach policy from cloud user", func(s *mcclient.ClientSession, opts *ClouduserPolicyOptions) error {
result, err := modules.Cloudusers.PerformAction(s, opts.ID, "detach-policy", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
type ClouduserPasswordOptions struct {
ID string `help:"Clouduser Id"`
Password string `help:"clouduser password"`
}
R(&ClouduserPasswordOptions{}, "cloud-user-reset-password", "Reset clouduser password", func(s *mcclient.ClientSession, opts *ClouduserPasswordOptions) error {
result, err := modules.Cloudusers.PerformAction(s, opts.ID, "reset-password", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
type ClouduserChangeOwnerOptions struct {
ID string `help:"clouduser id"`
USER_ID string `help:"local user id"`
}
R(&ClouduserChangeOwnerOptions{}, "cloud-user-change-owner", "Change clouduser owner", func(s *mcclient.ClientSession, opts *ClouduserChangeOwnerOptions) error {
result, err := modules.Cloudusers.PerformAction(s, opts.ID, "change-owner", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
type ClouduserGroupOptions struct {
ID string `help:"clouduser id"`
CLOUDGROUP_ID string `help:"cloudgroup id" json:"cloudgroup_id"`
}
R(&ClouduserGroupOptions{}, "cloud-user-join-group", "Join user to cloudgroup", func(s *mcclient.ClientSession, opts *ClouduserGroupOptions) error {
result, err := modules.Cloudusers.PerformAction(s, opts.ID, "join-group", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
R(&ClouduserGroupOptions{}, "cloud-user-leave-group", "Leave from cloudgroup", func(s *mcclient.ClientSession, opts *ClouduserGroupOptions) error {
result, err := modules.Cloudusers.PerformAction(s, opts.ID, "leave-group", jsonutils.Marshal(opts))
if err != nil {
return err
}
printObject(result)
return nil
})
}

View File

@@ -0,0 +1,26 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package cloudid
import (
"yunion.io/x/onecloud/cmd/climc/shell"
"yunion.io/x/onecloud/pkg/util/printutils"
)
var (
R = shell.R
printList = printutils.PrintJSONList
printObject = printutils.PrintJSONObject
)

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"
@@ -26,7 +26,7 @@ import (
"yunion.io/x/onecloud/pkg/mcclient/modulebase"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
objectshell "yunion.io/x/onecloud/pkg/multicloud/objectstore"
"yunion.io/x/onecloud/pkg/multicloud/objectstore"
)
func init() {
@@ -188,7 +188,7 @@ func init() {
StorageClass string `help:"storage CLass"`
Acl string `help:"object acl." choices:"private|public-read|public-read-write"`
objectshell.ObjectHeaderOptions
objectstore.ObjectHeaderOptions
}
R(&BucketUploadObjectsOptions{}, "bucket-object-upload", "Upload an object into a bucket", func(s *mcclient.ClientSession, args *BucketUploadObjectsOptions) error {
var body io.Reader
@@ -325,7 +325,7 @@ func init() {
Key []string `help:"Optional object key" json:"key"`
objectshell.ObjectHeaderOptions
objectstore.ObjectHeaderOptions
}
R(&BucketSetMetadataOptions{}, "bucket-set-metadata", "Set metadata of object", func(s *mcclient.ClientSession, args *BucketSetMetadataOptions) error {
input := api.BucketMetadataInput{}

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"
@@ -125,6 +125,22 @@ func init() {
printObject(result)
return nil
})
type SVMwareCloudAccountPrepareNetsOptions struct {
Project string `help:"project for this account"`
ProjectDomain string `help:"domain for this account"`
NAME string `help:"name for this account"`
options.SVMwareCredentialWithEnvironment
}
R(&SVMwareCloudAccountPrepareNetsOptions{}, "cloud-account-preparenets-vmware", "Prepare networks for a VMware cloud account before create this accout", func(s *mcclient.ClientSession, args *SVMwareCloudAccountPrepareNetsOptions) error {
params := jsonutils.Marshal(args)
params.(*jsonutils.JSONDict).Add(jsonutils.NewString("VMware"), "provider")
result, err := modules.Cloudaccounts.PerformClassAction(s, "prepare-nets", params)
if err != nil {
return err
}
printObject(result)
return nil
})
R(&options.SAliyunCloudAccountCreateOptions{}, "cloud-account-create-aliyun", "Create an Aliyun cloud account", func(s *mcclient.ClientSession, args *options.SAliyunCloudAccountCreateOptions) error {
params := jsonutils.Marshal(args)

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -0,0 +1,34 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package compute
import (
"yunion.io/x/onecloud/cmd/climc/shell"
"yunion.io/x/onecloud/pkg/util/printutils"
)
var (
R = shell.R
printList = printutils.PrintJSONList
printObject = printutils.PrintJSONObject
printBatchResults = printutils.PrintJSONBatchResults
InvalidUpdateError = shell.InvalidUpdateError
printObjectRecursive = printutils.PrintJSONObjectRecursive
exportList = shell.ExportList
printObjectRecursiveEx = printutils.PrintJSONObjectRecursiveEx
)

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"
@@ -46,9 +46,9 @@ func init() {
})
type EipCreateOptions struct {
MANAGER string `help:"cloud provider"`
REGION string `help:"cloud region in which EIP is allocated"`
NAME string `help:"name of the EIP"`
Manager string `help:"cloud provider"`
Region string `help:"cloud region in which EIP is allocated"`
Bandwidth int `help:"Bandwidth in Mbps"`
Ip string `help:"IP address of the EIP"`
Network string `help:"Network of the EIP"`
@@ -56,9 +56,13 @@ func init() {
}
R(&EipCreateOptions{}, "eip-create", "Create an EIP", func(s *mcclient.ClientSession, args *EipCreateOptions) error {
params := jsonutils.NewDict()
params.Add(jsonutils.NewString(args.MANAGER), "manager")
params.Add(jsonutils.NewString(args.REGION), "region")
params.Add(jsonutils.NewString(args.NAME), "name")
if args.Region != "" {
params.Add(jsonutils.NewString(args.Region), "region")
}
if args.Manager != "" {
params.Add(jsonutils.NewString(args.Manager), "manager")
}
if args.Bandwidth != 0 {
params.Add(jsonutils.NewInt(int64(args.Bandwidth)), "bandwidth")
}

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,9 +12,11 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"
"yunion.io/x/jsonutils"
"yunion.io/x/onecloud/pkg/mcclient"
@@ -78,4 +80,30 @@ func init() {
printObject(result)
return nil
})
R(&GlobalVpcShowOptions{}, "global-vpc-change-owner-candidate-domains", "Show candiate domains of a global vpc for changing owner", func(s *mcclient.ClientSession, args *GlobalVpcShowOptions) error {
result, err := modules.GlobalVpcs.GetSpecific(s, args.ID, "change-owner-candidate-domains", nil)
if err != nil {
return err
}
printObject(result)
return nil
})
type GlobalVpcChangeOwnerOptions struct {
ID string `help:"ID or name of vpc" json:"-"`
ProjectDomain string `json:"project_domain" help:"target domain"`
}
R(&GlobalVpcChangeOwnerOptions{}, "global-vpc-change-owner", "Change owner domain of a global vpc", func(s *mcclient.ClientSession, args *GlobalVpcChangeOwnerOptions) error {
if len(args.ProjectDomain) == 0 {
return fmt.Errorf("empty project_domain")
}
params := jsonutils.Marshal(args)
ret, err := modules.GlobalVpcs.PerformAction(s, args.ID, "change-owner", params)
if err != nil {
return err
}
printObject(ret)
return nil
})
}

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"
@@ -145,6 +145,15 @@ func init() {
},
)
R(&GuestTemplateOptions{}, "server-template-inspect", "Inspect server template", func(s *mcclient.ClientSession, opts *GuestTemplateOptions) error {
tem, err := modules.GuestTemplate.PerformAction(s, opts.ID, "inspect", jsonutils.JSONNull)
if err != nil {
return err
}
printObject(tem)
return nil
})
type GuestTemplatePublicOptions struct {
ID string `help:"ID or Name of server template"`
PublicScope string `help:"public scope"`

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"
@@ -815,4 +815,20 @@ func init() {
printObject(result)
return nil
})
type HostSetReservedResourceForIsolatedDevice struct {
ID []string `help:"ID or name of host" json:"-"`
ReservedCpu *int `help:"reserved cpu count"`
ReservedMem *int `help:"reserved mem count"`
ReservedStorage *int `help:"reserved storage count"`
}
R(&HostSetReservedResourceForIsolatedDevice{},
"host-set-reserved-resource-for-isolated-device",
"Set reserved resource for isolated device",
func(s *mcclient.ClientSession, args *HostSetReservedResourceForIsolatedDevice) error {
res := modules.Hosts.BatchPerformAction(s, args.ID, "set-reserved-resource-for-isolated-device", jsonutils.Marshal(args))
printBatchResults(res, modules.Hosts.GetColumns(s))
return nil
},
)
}

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"
@@ -84,4 +84,16 @@ func init() {
printObject(result)
return nil
})
type DeviceUpdateOptions struct {
ID []string `help:"ID of the isolated device" json:"-"`
ReservedCpu *int `help:"reserved cpu for isolated device"`
ReservedMem *int `help:"reserved mem for isolated device"`
ReservedStorage *int `help:"reserved storage for isolated device"`
}
R(&DeviceUpdateOptions{}, "isolated-device-update", "Update a isolated device", func(s *mcclient.ClientSession, args *DeviceUpdateOptions) error {
res := modules.IsolatedDevices.BatchUpdate(s, args.ID, jsonutils.Marshal(args))
printBatchResults(res, modules.IsolatedDevices.GetColumns(s))
return nil
})
}

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"encoding/base64"
@@ -70,6 +70,18 @@ func init() {
printLbagent(lbagent)
return nil
})
R(&options.LoadbalancerAgentDefaultParamsOptions{}, "lbagent-show-default-params", "Show lbagent default params", func(s *mcclient.ClientSession, opts *options.LoadbalancerAgentDefaultParamsOptions) error {
params, err := options.StructToParams(opts)
if err != nil {
return err
}
lbagent, err := modules.LoadbalancerAgents.Get(s, "default-params", params)
if err != nil {
return err
}
printLbagent(lbagent)
return nil
})
R(&options.LoadbalancerAgentListOptions{}, "lbagent-list", "List lbagents", func(s *mcclient.ClientSession, opts *options.LoadbalancerAgentListOptions) error {
params, err := options.ListStructToParams(opts)
if err != nil {

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"
@@ -37,7 +37,7 @@ func init() {
Region string `help:"search networks belongs to a CloudRegion" json:"cloudregion"`
City string `help:"search networks belongs to a city"`
Usable *bool `help:"search usable networks"`
ServerType string `help:"search networks belongs to a ServerType" choices:"guest|baremetal|container|pxe|ipmi"`
ServerType string `help:"search networks belongs to a ServerType" choices:"baremetal|container|eip|guest|ipmi|pxe"`
Schedtag string `help:"filter networks by schedtag"`
Status string `help:"filter by network status"`
@@ -68,7 +68,7 @@ func init() {
ID string `help:"ID or Name of zone to update"`
Name string `help:"Name of zone"`
Desc string `metavar:"<DESCRIPTION>" help:"Description"`
ServerType string `help:"server type," choices:"baremetal|guest|container|pxe|ipmi"`
ServerType string `help:"server type," choices:"baremetal|container|eip|guest|ipmi|pxe"`
StartIp string `help:"Start ip"`
EndIp string `help:"end ip"`
NetMask int64 `help:"Netmask"`
@@ -227,7 +227,7 @@ func init() {
VlanId int64 `help:"Vlan ID" default:"1"`
IfnameHint string `help:"Hint for ifname generation"`
AllocPolicy string `help:"Address allocation policy" choices:"none|stepdown|stepup|random"`
ServerType string `help:"Server type" choices:"baremetal|guest|container|pxe|ipmi"`
ServerType string `help:"Server type" choices:"baremetal|container|eip|guest|ipmi|pxe"`
Desc string `help:"Description" metavar:"DESCRIPTION"`
}
R(&NetworkCreateOptions{}, "network-create", "Create a virtual network", func(s *mcclient.ClientSession, args *NetworkCreateOptions) error {

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,9 +12,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"
"time"
"yunion.io/x/jsonutils"
@@ -25,6 +26,20 @@ import (
"yunion.io/x/onecloud/pkg/mcclient/options"
)
type Timer struct {
TimingExecTime string `help:"Exectime for 'timing' type trigger, format:'2006-01-02 15:04:05'" json:"exec_time"`
}
type CycleTimer struct {
CycleCycleType string `help:"Cycle type for cycle timer" json:"cycle_type" choices:"day|week|month"`
CycleMinute int `help:"Minute of cycle timer" json:"minute"`
CycleHour int `help:"Hour of cycle timer" json:"hour"`
CycleWeekdays []int `help:"Weekdays for cycle timer" json:"weekdays"`
CycleMonthDays []int `help:"Month days for cycle timer" json:"month_days"`
CycleStartTime string `help:"Start time for cycle timer, format:'2006-01-02 15:04:05'" json:"start_time"`
CycleEndTime string `help:"End time for cycle timer, format:'2006-01-02 15:04:05'" json:"end_time"`
}
func init() {
type ScalingPolicyListOptions struct {
options.BaseListOptions
@@ -57,20 +72,6 @@ func init() {
return nil
})
type ScalingTimer struct {
TimingExecTime time.Time `help:"Exectime for 'timing' type trigger" json:"exec_time"`
}
type ScalingCycleTimer struct {
CycleCycleType string `help:"Cycle type for 'cycle' type trigger" json:"cycle_type"`
CycleMinute int `help:"Minute of 'cycle' type trigger" json:"minute"`
CycleHour int `help:"Hour of 'cycle' type trigger" json:"hour"`
CycleWeekdays []int `help:"Weekdays for 'cycle' type trigger" json:"weekdays"`
CycleMonthDays []int `help:"Month days for 'cycle' type trigger" json:"month_days"`
CycleStartTime time.Time `help:"Start time for 'cycle' type trigger" json:"start_time"`
CycleEndTime time.Time `help:"End time for 'cycle' type trigger" json:"end_time"`
}
type ScalingAlarm struct {
AlarmCumulate int `help:"Cumulate times alarm will trigger, for 'alarm' trigger" json:"cumulate"`
AlarmCycle int `help:"Monitoring cycle for indicators, for 'alarm' trigger" json:"cycle"`
@@ -85,8 +86,8 @@ func init() {
ScalingGroup string `help:"ScalingGroup ID or Name" json:"scaling_group"`
TriggerType string `help:"Trigger type" choices:"alarm|timing|cycle" json:"trigger_type"`
ScalingTimer
ScalingCycleTimer
Timer
CycleTimer
ScalingAlarm
Action string `help:"Action for scaling policy" choices:"add|remove|set" json:"action"`
@@ -97,20 +98,33 @@ func init() {
R(&ScalingPolicyCreateOptions{}, "scaling-policy-create", "Create Scaling Policy",
func(s *mcclient.ClientSession, args *ScalingPolicyCreateOptions) error {
formatStr := "2006-01-02 15:04:05"
timingExecTime, err := time.Parse(formatStr, args.TimingExecTime)
if err != nil {
return fmt.Errorf("invalid time format for 'exec_time'")
}
cycleStarTime, err := time.Parse(formatStr, args.CycleStartTime)
if err != nil {
return fmt.Errorf("invalid time format for 'start_time'")
}
cycleEndTime, err := time.Parse(formatStr, args.CycleEndTime)
if err != nil {
return fmt.Errorf("invalid time format for 'end_time'")
}
spCreateInput := api.ScalingPolicyCreateInput{
ScalingGroup: args.ScalingGroup,
TriggerType: args.TriggerType,
Timer: api.ScalingTimerCreateInput{
args.TimingExecTime,
Timer: api.TimerCreateInput{
ExecTime: timingExecTime,
},
CycleTimer: api.ScalingCycleTimerCreateInput{
CycleTimer: api.CycleTimerCreateInput{
CycleType: args.CycleCycleType,
Minute: args.CycleMinute,
Hour: args.CycleHour,
WeekDays: args.CycleWeekdays,
MonthDays: args.CycleMonthDays,
StartTime: args.CycleStartTime,
EndTime: args.CycleEndTime,
StartTime: cycleStarTime,
EndTime: cycleEndTime,
},
Alarm: api.ScalingAlarmCreateInput{
Cumulate: args.AlarmCumulate,

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/jsonutils"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"

View File

@@ -0,0 +1,211 @@
// Copyright 2019 Yunion
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package compute
import (
"fmt"
"time"
"yunion.io/x/jsonutils"
apis "yunion.io/x/onecloud/pkg/apis/compute"
"yunion.io/x/onecloud/pkg/mcclient"
"yunion.io/x/onecloud/pkg/mcclient/modules"
"yunion.io/x/onecloud/pkg/mcclient/options"
)
func init() {
type ScheduledTaskListOptions struct {
options.BaseListOptions
ScheduledType string `help:"scheduled type" choices:"timing|cycle"`
ResourceType string `help:"resource type"`
Operation string `help:"operation"`
}
R(&ScheduledTaskListOptions{}, "scheduledtask-list", "list Scheduled Task", func(s *mcclient.ClientSession, args *ScheduledTaskListOptions) error {
params, err := options.ListStructToParams(args)
tasks, err := modules.ScheduledTask.List(s, params)
if err != nil {
return err
}
printList(tasks, modules.ScheduledTask.GetColumns(s))
return nil
})
type ScheduledTaskShowOptions struct {
ID string `help:"ScheduledTask ID or Name"`
}
R(&ScheduledTaskShowOptions{}, "scheudled-task-show", "Show Scheduled Task", func(s *mcclient.ClientSession,
args *ScheduledTaskShowOptions) error {
params := jsonutils.NewDict()
params.Set("details", jsonutils.JSONTrue)
task, err := modules.ScheduledTask.Get(s, args.ID, params)
if err != nil {
return err
}
printObject(task)
return nil
})
type ScheduledTaskCreateOptions struct {
NAME string `help:"ScheduledTask Name" json:"name"`
ScheduledType string `help:"Scheudled Type" choices:"timing|cycle" json:"scheduled_type"`
Timer
CycleTimer
ResourceType string `help:"resource type"`
Operation string `help:"operation"`
LabelType string `help:"label type"`
Labels []string `help:"labels"`
}
R(&ScheduledTaskCreateOptions{}, "scheduledtask-create", "Create Scheduled Task", func(s *mcclient.ClientSession, args *ScheduledTaskCreateOptions) error {
formatStr := "2006-01-02 15:04:05"
var exectime, starttime, endtime time.Time
var err error
if len(args.TimingExecTime) > 0 {
exectime, err = time.Parse(formatStr, args.TimingExecTime)
if err != nil {
return fmt.Errorf("invalid time format for 'exec_time'")
}
}
if len(args.CycleStartTime) > 0 {
starttime, err = time.Parse(formatStr, args.CycleStartTime)
if err != nil {
return fmt.Errorf("invalid time format for 'start_time'")
}
}
if len(args.CycleEndTime) > 0 {
endtime, err = time.Parse(formatStr, args.CycleEndTime)
if err != nil {
return fmt.Errorf("invalid time format for 'end_time'")
}
}
stCreateInput := apis.ScheduledTaskCreateInput{
ScheduledType: args.ScheduledType,
Timer: apis.TimerCreateInput{
ExecTime: exectime,
},
CycleTimer: apis.CycleTimerCreateInput{
CycleType: args.CycleCycleType,
Minute: args.CycleMinute,
Hour: args.CycleHour,
WeekDays: args.CycleWeekdays,
MonthDays: args.CycleMonthDays,
StartTime: starttime,
EndTime: endtime,
},
ResourceType: args.ResourceType,
Operation: args.Operation,
LabelType: args.LabelType,
Labels: args.Labels,
}
stCreateInput.Name = args.NAME
ret, err := modules.ScheduledTask.Create(s, jsonutils.Marshal(stCreateInput))
if err != nil {
return err
}
printObject(ret)
return nil
})
type ScheduledTaskEnableOptions struct {
ID string `help:"ScheduledTask ID or Name"`
}
R(&ScheduledTaskEnableOptions{}, "scheduledtask-enable", "Enable ScheduledTask", func(s *mcclient.ClientSession,
args *ScheduledTaskEnableOptions) error {
ret, err := modules.ScheduledTask.PerformAction(s, args.ID, "enable", jsonutils.NewDict())
if err != nil {
return err
}
printObject(ret)
return nil
})
R(&ScheduledTaskEnableOptions{}, "scheduledtask-disable", "Disable ScheduledTask",
func(s *mcclient.ClientSession, args *ScheduledTaskEnableOptions) error {
ret, err := modules.ScheduledTask.PerformAction(s, args.ID, "disable", jsonutils.NewDict())
if err != nil {
return err
}
printObject(ret)
return nil
},
)
type ScheduledTaskSetLabelsOptions struct {
ID string `help:"ScheduledTask ID or Name"`
Labels []string `help:"Label"`
}
R(&ScheduledTaskSetLabelsOptions{}, "scheduledtask-setlabels", "Trigger ScheduledTask's action",
func(s *mcclient.ClientSession, args *ScheduledTaskSetLabelsOptions) error {
params := jsonutils.NewDict()
params.Set("labels", jsonutils.Marshal(args.Labels))
ret, err := modules.ScheduledTask.PerformAction(s, args.ID, "set-labels", params)
if err != nil {
return err
}
printObject(ret)
return nil
},
)
type ScheduledTaskTriggerOptions struct {
ID string `help:"ScheduledTask ID or Name"`
}
R(&ScheduledTaskTriggerOptions{}, "scheduledtask-trigger", "Trigger ScheduledTask",
func(s *mcclient.ClientSession, args *ScheduledTaskTriggerOptions) error {
params := jsonutils.NewDict()
ret, err := modules.ScheduledTask.PerformAction(s, args.ID, "trigger", params)
if err != nil {
return err
}
printObject(ret)
return nil
},
)
type ScheduledTaskDeleteOptions struct {
ID string `help:"ScheduledTask ID or Name"`
}
R(&ScheduledTaskDeleteOptions{}, "scheduledtask-delete", "Delete ScheduledTask",
func(s *mcclient.ClientSession, args *ScheduledTaskDeleteOptions) error {
ret, err := modules.ScheduledTask.Delete(s, args.ID, jsonutils.NewDict())
if err != nil {
return err
}
printObject(ret)
return nil
},
)
type ScheduledTaskAvtivityListOptions struct {
options.BaseListOptions
ScheduledTask string `help:"Scheduled Task" json:"scheduled_task"`
}
R(&ScheduledTaskAvtivityListOptions{}, "scheduledtask-activity-list", "List Scheduled Task Activity",
func(s *mcclient.ClientSession, args *ScheduledTaskAvtivityListOptions) error {
params, err := options.ListStructToParams(args)
if err != nil {
return err
}
list, err := modules.ScheduledTaskActivity.List(s, params)
if err != nil {
return err
}
printList(list, modules.ScheduledTaskActivity.GetColumns(s))
return nil
},
)
}

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"fmt"
@@ -111,10 +111,11 @@ func init() {
type SchedulerCleanCacheOptions struct {
HostId string `help:"ID of host" short-token:"h"`
SessionId string `help:"Session id" short-token:"s"`
Sync bool `help:"Sync do clean sched cache"`
}
R(&SchedulerCleanCacheOptions{}, "scheduler-clean-cache", "Clean scheduler hosts cache",
func(s *mcclient.ClientSession, args *SchedulerCleanCacheOptions) error {
err := modules.SchedManager.CleanCache(s, args.HostId, args.SessionId)
err := modules.SchedManager.CleanCache(s, args.HostId, args.SessionId, args.Sync)
if err != nil {
return err
}

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
package shell
package compute
import (
"yunion.io/x/onecloud/pkg/mcclient"

Some files were not shown because too many files have changed in this diff Show More