zz_generated.model.go 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352
  1. // Licensed under the Apache License, Version 2.0 (the "License");
  2. // you may not use this file except in compliance with the License.
  3. // You may obtain a copy of the License at
  4. //
  5. // http://www.apache.org/licenses/LICENSE-2.0
  6. //
  7. // Unless required by applicable law or agreed to in writing, software
  8. // distributed under the License is distributed on an "AS IS" BASIS,
  9. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  10. // See the License for the specific language governing permissions and
  11. // limitations under the License.
  12. // Code generated by model-api-gen. DO NOT EDIT.
  13. package cloudprovider
  14. // CacheKeyRule is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.CacheKeyRule.
  15. type CacheKeyRule struct {
  16. RulePaths []string `json:"rule_paths"`
  17. RuleType string `json:"rule_type"`
  18. FullUrlCache bool `json:"full_url_cache"`
  19. IgnoreCase bool `json:"ignore_case"`
  20. QueryString CacheKeyRuleQueryString `json:"query_string"`
  21. RuleTag string `json:"rule_tag"`
  22. }
  23. // CacheKeyRuleQueryString is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.CacheKeyRuleQueryString.
  24. type CacheKeyRuleQueryString struct {
  25. Enabled bool `json:"enabled"`
  26. Action string `json:"action"`
  27. Value string `json:"value"`
  28. }
  29. // DefaultAction is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.DefaultAction.
  30. type DefaultAction struct {
  31. // Allow, Block, Log, Count, Alert, Detection, Prevention
  32. Action string `json:"action"`
  33. // 仅Action为Allow时生效
  34. InsertHeaders map[string]string `json:"insert_headers"`
  35. // 仅Action为Block时生效
  36. Response string `json:"response"`
  37. // 仅Action为Block时生效
  38. ResponseCode *int `json:"response_code"`
  39. // 仅Action为Block时生效
  40. ResponseHeaders map[string]string `json:"response_headers"`
  41. }
  42. // ElasticSearchAccessInfo is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.ElasticSearchAccessInfo.
  43. type ElasticSearchAccessInfo struct {
  44. Domain string `json:"domain"`
  45. PrivateDomain string `json:"private_domain"`
  46. Vip string `json:"vip"`
  47. Port int `json:"port"`
  48. PrivatePort int `json:"private_port"`
  49. KibanaUrl string `json:"kibana_url"`
  50. KibanaPrivateUrl string `json:"kibana_private_url"`
  51. }
  52. // RefererRule is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.RefererRule.
  53. type RefererRule struct {
  54. // 规则类型:
  55. // all:所有文件生效
  56. // file:指定文件后缀生效
  57. // directory:指定路径生效
  58. // path:指定绝对路径生效
  59. RuleType string `json:"rule_type"`
  60. RulePaths []string `json:"rule_paths"`
  61. RefererType string `json:"referer_type"`
  62. Referers []string `json:"referers"`
  63. AllowEmpty *bool `json:"allow_empty"`
  64. }
  65. // RuleCacheConfig is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.RuleCacheConfig.
  66. type RuleCacheConfig struct {
  67. Cache *struct {
  68. Enabled bool
  69. CacheTime int
  70. CompareMaxAge bool
  71. IgnoreCacheControl bool
  72. IgnoreSetCookie bool
  73. } `json:"cache"`
  74. NoCache *struct {
  75. Enabled bool
  76. Revalidate bool
  77. } `json:"no_cache"`
  78. FollowOrigin *struct {
  79. Enabled bool
  80. HeuristicCache struct {
  81. Enabled bool
  82. CacheConfig struct {
  83. HeuristicCacheTimeSwitch bool
  84. HeuristicCacheTime int
  85. }
  86. }
  87. } `json:"follow_origin"`
  88. }
  89. // SCDNCache is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCDNCache.
  90. type SCDNCache struct {
  91. RuleCache []SCacheRuleCache `json:"rule_cache"`
  92. }
  93. // SCDNCacheKeys is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCDNCacheKeys.
  94. type SCDNCacheKeys struct {
  95. // 开启关闭忽略参数
  96. Enabled *bool `json:"enabled"`
  97. // 是否忽略大小
  98. IgnoreCase *bool `json:"ignore_case"`
  99. // 分路径缓存键配置
  100. KeyRules []CacheKeyRule `json:"key_rules"`
  101. }
  102. // SCDNForceRedirect is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCDNForceRedirect.
  103. type SCDNForceRedirect struct {
  104. // 访问强制跳转配置开关
  105. Enabled *bool `json:"enabled"`
  106. // 访问强制跳转类型
  107. // enmu: http, https
  108. RedirectType string `json:"redirect_type"`
  109. }
  110. // SCDNHttps is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCDNHttps.
  111. type SCDNHttps struct {
  112. // https 配置开关
  113. Enabled *bool `json:"enabled"`
  114. // http2 配置开关
  115. Http2 *bool `json:"http2"`
  116. }
  117. // SCDNMaxAge is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCDNMaxAge.
  118. type SCDNMaxAge struct {
  119. Enabled *bool `json:"enabled"`
  120. MaxAgeRules []SMaxAgeRule `json:"max_age_rules"`
  121. }
  122. // SCDNRangeOriginPull is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCDNRangeOriginPull.
  123. type SCDNRangeOriginPull struct {
  124. Enabled *bool `json:"enabled"`
  125. RangeOriginPullRules []SRangeOriginPullRule `json:"range_origin_pull_rules"`
  126. }
  127. // SCDNReferer is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCDNReferer.
  128. type SCDNReferer struct {
  129. // 是否开启防盗链
  130. Enabled *bool `json:"enabled"`
  131. RefererRules []RefererRule `json:"referer_rules"`
  132. }
  133. // SCacheRuleCache is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCacheRuleCache.
  134. type SCacheRuleCache struct {
  135. RulePaths []string `json:"rule_paths"`
  136. RuleType string `json:"rule_type"`
  137. Priority int `json:"priority"`
  138. CacheConfig *RuleCacheConfig `json:"cache_config"`
  139. }
  140. // SCdnDomain is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCdnDomain.
  141. type SCdnDomain struct {
  142. // cdn加速域名
  143. Domain string `json:"domain"`
  144. // 状态 rejected(域名未审核)|processing(部署中)|online|offline
  145. Status string `json:"status"`
  146. // 区域 mainland|overseas|global
  147. Area string `json:"area"`
  148. // cdn Cname
  149. Cname string `json:"cname"`
  150. // 源站
  151. Origin string `json:"origin"`
  152. // 源站类型 domain|ip|bucket
  153. OriginType string `json:"origin_type"`
  154. }
  155. // SCdnOrigin is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCdnOrigin.
  156. type SCdnOrigin struct {
  157. // 源站类型
  158. // domain: 域名类型, cos:对象存储源站, ip:IP 列表作为源站
  159. // enmu: domain, cos, ip
  160. // required: true
  161. Type string `json:"type"`
  162. // 源站地址
  163. Origin string `json:"origin"`
  164. // 回主源站时 Host 头部
  165. ServerName string `json:"server_name"`
  166. // 回源协议
  167. // enmu: http, follow, https
  168. Protocol string `json:"protocol"`
  169. Path string `json:"path"`
  170. Port int `json:"port"`
  171. Enabled string `json:"enabled"`
  172. Priority int `json:"priority"`
  173. }
  174. // SCdnOrigins is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SCdnOrigins.
  175. type SCdnOrigins []SCdnOrigin
  176. // SExcludeRule is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SExcludeRule.
  177. type SExcludeRule struct {
  178. Name string `json:"name"`
  179. }
  180. // SExcludeRules is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SExcludeRules.
  181. type SExcludeRules []SExcludeRule
  182. // SGeographicInfo is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SGeographicInfo.
  183. type SGeographicInfo struct {
  184. // 纬度
  185. // example: 26.647003
  186. Latitude float32 `json:"latitude"`
  187. // 经度
  188. // example: 106.630211
  189. Longitude float32 `json:"longitude"`
  190. // 城市
  191. // example: Guiyang
  192. City string `json:"city"`
  193. // 国家代码
  194. // example: CN
  195. CountryCode string `json:"country_code"`
  196. }
  197. // SMaxAgeRule is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SMaxAgeRule.
  198. type SMaxAgeRule struct {
  199. MaxAgeType string `json:"max_age_type"`
  200. MaxAgeContents []string `json:"max_age_contents"`
  201. MaxAgeTime int `json:"max_age_time"`
  202. FollowOrigin bool `json:"follow_origin"`
  203. }
  204. // SRangeOriginPullRule is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SRangeOriginPullRule.
  205. type SRangeOriginPullRule struct {
  206. Enabled bool `json:"enabled"`
  207. RuleType string `json:"rule_type"`
  208. RulePaths []string `json:"rule_paths"`
  209. }
  210. // SSubAccount is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SSubAccount.
  211. type SSubAccount struct {
  212. Id string `json:"id"`
  213. // 若Account不为空,可不传
  214. Name string `json:"name"`
  215. // 描述信息
  216. Desc string `json:"desc"`
  217. // 输入必填,若为空,需要指定子账号名称
  218. Account string `json:"account"`
  219. HealthStatus string `json:"health_status"`
  220. // 云端服务健康状态。例如欠费、项目冻结都属于不健康状态。
  221. DefaultProjectId string `json:"default_project_id"`
  222. }
  223. // SWafStatement is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SWafStatement.
  224. type SWafStatement struct {
  225. // 管理规则组名称
  226. ManagedRuleGroupName string `json:"managed_rule_group_name"`
  227. // 不包含的规则列表
  228. ExcludeRules *SExcludeRules `json:"exclude_rules"`
  229. // 表达式类别
  230. // enmu: ByteMatch, GeoMatch, IPSet, LabelMatch, ManagedRuleGroup, Rate, RegexSet, RuleGroup, Size, SqliMatch, XssMatch
  231. Type string `json:"type"`
  232. // 是否取反操作, 仅对Azure生效
  233. Negation bool `json:"negation"`
  234. // 操作类型
  235. // enum: EQ, NE, LE, LT, GE, GT
  236. Operator string `json:"operator"`
  237. // 匹配字段
  238. // enmu: Body, JsonBody, Query, Method, Header, UriPath, PostArgs, Cookie
  239. MatchField string `json:"match_field"`
  240. // 匹配字段的key
  241. MatchFieldKey string `json:"match_field_key"`
  242. // 匹配字段的值列表
  243. MatchFieldValues *TWafMatchFieldValues `json:"match_field_values"`
  244. // 进行转换操作
  245. // enmu: CompressWithSpace, HtmlEntityDecode, Lowercase, CmdLine, UrlDecode, Trim, UrlEncode, RemoveNulls
  246. Transformations *TextTransformations `json:"transformations"`
  247. ForwardedIPHeader string `json:"forwarded_ip_header"`
  248. // 搜索字段, 仅Aws有用
  249. SearchString string `json:"search_string"`
  250. IPSetId string `json:"ip_set_id"`
  251. // 正则表达式Id, 目前只读
  252. RegexSetId string `json:"regex_set_id"`
  253. // 自定义规则组Id, 目前只读
  254. RuleGroupId string `json:"rule_group_id"`
  255. }
  256. // ServerVncInput is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.ServerVncInput.
  257. type ServerVncInput struct {
  258. // 是否使用原生vnc控制台,此选项仅对openstack有效
  259. // default: false
  260. Origin bool `json:"origin"`
  261. }
  262. // ServerVncOutput is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.ServerVncOutput.
  263. type ServerVncOutput struct {
  264. Id string `json:"id"`
  265. // baremetal
  266. HostId string `json:"host_id"`
  267. Zone string `json:"zone"`
  268. // kvm host ip
  269. Host string `json:"host"`
  270. Protocol string `json:"protocol"`
  271. Port int64 `json:"port"`
  272. // volcengine
  273. Region string `json:"region"`
  274. Url string `json:"url"`
  275. InstanceId string `json:"instance_id"`
  276. InstanceName string `json:"instance_name"`
  277. Password string `json:"password"`
  278. VncPassword string `json:"vnc_password"`
  279. OsName string `json:"os_name"`
  280. // cloudpods
  281. ApiServer string `json:"api_server"`
  282. ConnectParams string `json:"connect_params"`
  283. Session string `json:"session"`
  284. Hypervisor string `json:"hypervisor"`
  285. }
  286. // SubAccounts is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.SubAccounts.
  287. type SubAccounts struct {
  288. // 若输出则是全量子账号列表,若输入,代表允许同步的子账号
  289. Accounts []SSubAccount `json:"accounts"`
  290. // 若输出是云账号查询到的区域列表,若输入,代表允许同步的区域
  291. Cloudregions []struct {
  292. Id string
  293. Name string
  294. Status string
  295. } `json:"cloudregions"`
  296. }
  297. // TWafAction is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.TWafAction.
  298. type TWafAction string
  299. // TWafMatchField is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.TWafMatchField.
  300. type TWafMatchField string
  301. // TWafMatchFieldValues is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.TWafMatchFieldValues.
  302. type TWafMatchFieldValues []string
  303. // TWafOperator is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.TWafOperator.
  304. type TWafOperator string
  305. // TWafStatementType is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.TWafStatementType.
  306. type TWafStatementType string
  307. // TWafTextTransformation is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.TWafTextTransformation.
  308. type TWafTextTransformation string
  309. // TextTransformations is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.TextTransformations.
  310. type TextTransformations []TWafTextTransformation
  311. // WafAddresses is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.WafAddresses.
  312. type WafAddresses []string
  313. // WafRegexPatterns is an autogenerated struct via yunion.io/x/cloudmux/pkg/cloudprovider.WafRegexPatterns.
  314. type WafRegexPatterns []string