我在Rancher测试了一些HPA,虽然它们在大多数情况下都很好,但我们有理由希望能够通过Rancher API触发扩展。
但是,我找不到任何关于这方面的好文档,也找不到任何关于这是否可能的确认。
我在网上发现了类似的问题,答案是“用HPA代替。”
Api文档指向api/v3/ url,并声明在那里很容易找到所需的内容。
我找不到关于荚/工作负载的方法,也找不到任何POST方法来处理豆荚的大小。
我是不是在文档中遗漏了一些明显的东西,比如api中的索引。
我查看了链接,查看了集群、节点和项目,没有任何运气。
links": {
"authConfigs": "…/v3/authconfigs",
"catalogs": "…/v3/catalogs",
"cisBenchmarkVersions": "…/v3/cisbenchmarkversions",
"cisConfigs": "…/v3/cisconfigs",
"cloudCredentials": "…/v3/cloudcredentials",
"clusterAlertGroups": "…/v3/clusteralertgroups",
"clusterAlertRules": "…/v3/clusteralertrules",
"clusterAlerts": "…/v3/clusteralerts",
"clusterCatalogs": "…/v3/clustercatalogs",
"clusterLoggings": "…/v3/clusterloggings",
"clusterMonitorGraphs": "…/v3/clustermonitorgraphs",
"clusterRegistrationTokens": "…/v3/clusterregistrationtokens",
"clusterRoleTemplateBindings": "…/v3/clusterroletemplatebindings",
"clusterScans": "…/v3/clusterscans",
"clusterTemplateRevisions": "…/v3/clustertemplaterevisions",
"clusterTemplates": "…/v3/clustertemplates",
"clusters": "…/v3/clusters",
"composeConfigs": "…/v3/composeconfigs",
"dynamicSchemas": "…/v3/dynamicschemas",
"etcdBackups": "…/v3/etcdbackups",
"features": "…/v3/features",
"fleetWorkspaces": "…/v3/fleetworkspaces",
"globalDnsProviders": "…/v3/globaldnsproviders",
"globalDnses": "…/v3/globaldnses",
"globalRoleBindings": "…/v3/globalrolebindings",
"globalRoles": "…/v3/globalroles",
"groupMembers": "…/v3/groupmembers",
"groups": "…/v3/groups",
"kontainerDrivers": "…/v3/kontainerdrivers",
"ldapConfigs": "…/v3/ldapconfigs",
"managementSecrets": "…/v3/managementsecrets",
"monitorMetrics": "…/v3/monitormetrics",
"multiClusterAppRevisions": "…/v3/multiclusterapprevisions",
"multiClusterApps": "…/v3/multiclusterapps",
"nodeDrivers": "…/v3/nodedrivers",
"nodePools": "…/v3/nodepools",
"nodeTemplates": "…/v3/nodetemplates",
"nodes": "…/v3/nodes",
"notifiers": "…/v3/notifiers",
"podSecurityPolicyTemplateProjectBindings": "…/v3/podsecuritypolicytemplateprojectbindings",
"podSecurityPolicyTemplates": "…/v3/podsecuritypolicytemplates",
"preferences": "…/v3/preferences",
"principals": "…/v3/principals",
"projectAlertGroups": "…/v3/projectalertgroups",
"projectAlertRules": "…/v3/projectalertrules",
"projectAlerts": "…/v3/projectalerts",
"projectCatalogs": "…/v3/projectcatalogs",
"projectLoggings": "…/v3/projectloggings",
"projectMonitorGraphs": "…/v3/projectmonitorgraphs",
"projectNetworkPolicies": "…/v3/projectnetworkpolicies",
"projectRoleTemplateBindings": "…/v3/projectroletemplatebindings",
"projects": "…/v3/projects",
"rkeAddons": "…/v3/rkeaddons",
"rkeK8sServiceOptions": "…/v3/rkek8sserviceoptions",
"rkeK8sSystemImages": "…/v3/rkek8ssystemimages",
"roleTemplates": "…/v3/roletemplates",
"root": "…/v3",
"samlTokens": "…/v3/samltokens",
"self": "…/v3",
"settings": "…/v3/settings",
"subscribe": "…/v3/subscribe",
"templateVersions": "…/v3/templateversions",
"templates": "…/v3/templates",
"tokens": "…/v3/tokens",
"users": "…/v3/users"发布于 2022-07-13 11:59:43
卧式吊舱自动标度是不可能通过牧场主API,但您可以管理您的HPA根据您的版本库伯内特斯API。
使用HPA,您可以自动缩放复制控制器、部署或复制设置或下降中的荚数。HPA自动缩放运行效率最高的荚数。
对于Kubernetes API版本,自动标度/V2beta1:这个版本的Kubernetes API允许您根据应用程序的CPU和内存利用率自动调节您的吊舱。
对于Kubernetes API版本,自动标度/V2beta2:这个版本的Kubernetes API允许您根据CPU和内存利用率自动调节您的豆荚,此外还可以使用自定义度量。
您可以使用Rancher UI创建、管理和删除HPA。在Rancher UI中,您可以根据CPU和内存利用率来配置HPA。有关更多信息,请参阅使用Rancher UI管理HPA。要根据自定义度量来扩展HPA,仍然需要使用kubectl。有关更多信息,请参阅使用Prometheus自定义度量将HPA配置为缩放。
https://stackoverflow.com/questions/72949308
复制相似问题