Files
cloudpods/docs/schemas/network.yaml
2019-06-29 10:41:38 +08:00

288 lines
6.3 KiB
YAML

NetworkCreate:
type: object
properties:
name:
type: string
example: test-network
description: 子网名称
wire:
type: string
example: wire1
description: ID or Name of wire in which the network created
guest_ip_start:
type: string
example: 10.168.10.100
description: 子网起始IP
guest_ip_end:
type: string
example: 10.168.10.199
description: 子网结束IP
guest_ip_mask:
type: string
example: 255.255.255.0
description: 子网掩码
guest_gateway:
type: string
example: 10.168.10.1
description: 网关
alloc_policy:
type: string
example: none
enmu: [none,stepdown,stepup,random]
description: IP分配策略
server_type:
type: string
example: guest
enmu: [baremetal,guest,container,pxe,ipmi]
description: 子网分配机器类型
vlan_id:
type: integer
example: 1
description: vlan ID
desc:
type: string
example: this is test network
description: 子网描述信息
guest_dns:
type: string
example: 8.8.8.8
description: DNS server
guest_domain:
type: string
example: test
description: domain name
guest_dhcp:
type: string
example: 192.168.10.1
description: DHCP server
NetworkResponse:
type: object
properties:
network:
type: object
$ref: '#/Network'
Network:
type: object
description: 网络
properties:
id:
type: string
example: c427c4ce-6870-19f3-8257-f53e63f40361
description: 子网uuid
readOnly: true
name:
type: string
description: 子网名称
example: network-r4hilqks
readOnly: true
brand:
type: string
example: OneCloud
description: 虚拟化品牌
can_delete:
type: boolean
description: 是否可删除
can_update:
type: boolean
description: 是否可以更新资源属性
created_at:
type: string
example: 2019-05-30T02:25:38.000000Z
description: 资源创建时间
is_emulated:
type: boolean
example: false
description: 是否是虚拟出来的实例
provider:
type: string
example: OneCloud
description: 纳管云平台
region:
type: string
example: region1
description: 区域名称
region_id:
type: string
example: 13947bd8-569e-4094-8b03-4339c2a8e45b
description: 区域ID
zone:
type: string
example: zone1
description: 可用区名称
zone_id:
type: string
example: a16d3e0b-3fd6-45ec-8b2d-e51a51fa0efc
description: 可用区ID
update_version:
type: integer
example: 2
description: 资源被更新的次数
updated_at:
type: string
example: 2019-05-30T06:36:39.000000Z
description: 资源最近一次更新时间
status:
type: string
example: available
description: 子网状态
wire:
type: string
example: bcast0
description: wire 名称
wire_id:
type: string
example: 89bb9ccc-c753-432d-96ae-b4c94ca45398
guest_ip_start:
type: string
example: 10.168.10.100
description: 子网起始IP
guest_ip_end:
type: string
example: 10.168.10.199
description: 子网结束IP
guest_ip_mask:
type: string
example: 255.255.255.0
description: 子网掩码
guest_gateway:
type: string
example: 10.168.10.1
description: 网关
alloc_policy:
type: string
example: none
description: IP分配策略
server_type:
type: string
example: guest
description: 子网分配机器类型
vlan_id:
type: integer
example: 1
description: vlan ID
vpc:
type: string
example: Default
description: vpc Name
vpc_id:
type: string
example: default
description: vpc ID
vnics:
type: integer
example: 10
description: 网卡数量
ports:
type: integer
example: 200
description: 可用IP数量
used_ports:
type: integer
example: 10
description: 已经使用IP数量
NetworkListResponse:
type: object
properties:
limit:
type: integer
example: 20
storages:
type: array
items:
$ref: '#/Network'
total:
type: integer
example: 124
NetworkUpdate:
type: object
properties:
name:
type: string
example: test-network2
description: IP子网名称
guest_ip_end:
type: string
example: 10.168.10.199
description: 子网结束IP
guest_ip_mask:
type: string
example: 255.255.255.0
description: 子网掩码
guest_gateway:
type: string
example: 10.168.10.1
description: 网关
alloc_policy:
type: string
example: none
description: IP分配策略
server_type:
type: string
example: guest
description: 子网分配机器类型
vlan_id:
type: integer
example: 1
description: vlan ID
desc:
type: string
example: this is test network
description: 子网描述信息
guest_dns:
type: string
example: 8.8.8.8
description: DNS server
guest_domain:
type: string
example: test
description: domain name
guest_dhcp:
type: string
example: 192.168.10.1
description: DHCP server
NetworkSplit:
type: object
properties:
split_ip:
type: string
example: 10.168.1.100
description: 用于分割子网的IP
require: true
name:
type: string
example: new-network
description: new network name
NetworkMerge:
type: object
properties:
target:
type: string
example: network2
description: network merge target
NetworkReserveIp:
type: object
properties:
ips:
type: array
example: ["192.168.10.1","192.168.10.2"]
description: reserve ips
notes:
type: string
example: reserve for test
description: reserve ip notes
NetworkReleaseReserveIp:
type: object
properties:
ip:
type: string
example: 192.168.10.1
description: release reserve ip