You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

50 lines
1.8 KiB

  1. # Copyright 2016 The Kubernetes Authors.
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License");
  4. # you may not use this file except in compliance with the License.
  5. # You may obtain a copy of the License at
  6. #
  7. # http://www.apache.org/licenses/LICENSE-2.0
  8. #
  9. # Unless required by applicable law or agreed to in writing, software
  10. # distributed under the License is distributed on an "AS IS" BASIS,
  11. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. # See the License for the specific language governing permissions and
  13. # limitations under the License.
  14. apiVersion: extensions/v1beta1
  15. kind: Deployment
  16. metadata:
  17. name: dnsmasq-autoscaler
  18. namespace: kube-system
  19. labels:
  20. k8s-app: dnsmasq-autoscaler
  21. kubernetes.io/cluster-service: "true"
  22. addonmanager.kubernetes.io/mode: Reconcile
  23. spec:
  24. template:
  25. metadata:
  26. labels:
  27. k8s-app: dnsmasq-autoscaler
  28. annotations:
  29. scheduler.alpha.kubernetes.io/critical-pod: ''
  30. scheduler.alpha.kubernetes.io/tolerations: '[{"key":"CriticalAddonsOnly", "operator":"Exists"}]'
  31. spec:
  32. containers:
  33. - name: autoscaler
  34. image: gcr.io/google_containers/cluster-proportional-autoscaler-amd64:1.1.1
  35. resources:
  36. requests:
  37. cpu: "20m"
  38. memory: "10Mi"
  39. command:
  40. - /cluster-proportional-autoscaler
  41. - --namespace=kube-system
  42. - --configmap=dnsmasq-autoscaler
  43. - --target=Deployment/dnsmasq
  44. # When cluster is using large nodes(with more cores), "coresPerReplica" should dominate.
  45. # If using small nodes, "nodesPerReplica" should dominate.
  46. - --default-params={"linear":{"nodesPerReplica":{{ dnsmasq_nodes_per_replica }},"preventSinglePointFailure":true}}
  47. - --logtostderr=true
  48. - --v={{ kube_log_level }}