From 486344593ebaa718ed4057c1b7ec47be7dbfa6a8 Mon Sep 17 00:00:00 2001 From: Jamie Thompson Date: Sat, 18 Jul 2020 22:07:51 +0100 Subject: [PATCH] Update examples to CPA CRD v1 (#30) --- docs/reference/configuration.md | 5 +++-- example/persistent-linear/phpa.yaml | 3 ++- example/simple-holt-winters/phpa.yaml | 5 +++-- example/simple-linear/phpa.yaml | 3 ++- 4 files changed, 10 insertions(+), 6 deletions(-) diff --git a/docs/reference/configuration.md b/docs/reference/configuration.md index 2ad7e0d..05a1378 100644 --- a/docs/reference/configuration.md +++ b/docs/reference/configuration.md @@ -7,7 +7,7 @@ Beyond specifying models, other configuration options can be set in the `predict Predictive Configuration is provided through environment variables, which can be supplied through the Custom Pod Autoscaler YAML shorthand: ```yaml -apiVersion: custompodautoscaler.com/v1alpha1 +apiVersion: custompodautoscaler.com/v1 kind: CustomPodAutoscaler metadata: name: simple-linear-example @@ -22,6 +22,7 @@ spec: apiVersion: apps/v1 kind: Deployment name: php-apache + provisionRole: false config: - name: minReplicas value: "1" @@ -137,4 +138,4 @@ Example: tolerance: 0.25 ``` Default value: `0.1`. -Equivalent to `--horizontal-pod-autoscaler-tolerance`; the minimum change (from 1.0) in the desired-to-actual metrics ratio for the horizontal pod autoscaler to consider scaling. \ No newline at end of file +Equivalent to `--horizontal-pod-autoscaler-tolerance`; the minimum change (from 1.0) in the desired-to-actual metrics ratio for the horizontal pod autoscaler to consider scaling. diff --git a/example/persistent-linear/phpa.yaml b/example/persistent-linear/phpa.yaml index 51358a2..53508bf 100644 --- a/example/persistent-linear/phpa.yaml +++ b/example/persistent-linear/phpa.yaml @@ -57,7 +57,7 @@ spec: requests: storage: 10Mi --- -apiVersion: custompodautoscaler.com/v1alpha1 +apiVersion: custompodautoscaler.com/v1 kind: CustomPodAutoscaler metadata: name: predictive-horizontal-pod-autoscaler-example @@ -79,6 +79,7 @@ spec: apiVersion: apps/v1 kind: Deployment name: php-apache + provisionRole: false config: - name: minReplicas value: "1" diff --git a/example/simple-holt-winters/phpa.yaml b/example/simple-holt-winters/phpa.yaml index 81c301f..275a416 100644 --- a/example/simple-holt-winters/phpa.yaml +++ b/example/simple-holt-winters/phpa.yaml @@ -29,7 +29,7 @@ rules: verbs: - '*' --- -apiVersion: custompodautoscaler.com/v1alpha1 +apiVersion: custompodautoscaler.com/v1 kind: CustomPodAutoscaler metadata: name: simple-holt-winters-example @@ -44,6 +44,7 @@ spec: apiVersion: apps/v1 kind: Deployment name: php-apache + provisionRole: false config: - name: minReplicas value: "1" @@ -75,4 +76,4 @@ spec: - name: startTime value: "60000" - name: downscaleStabilization - value: "30" \ No newline at end of file + value: "30" diff --git a/example/simple-linear/phpa.yaml b/example/simple-linear/phpa.yaml index a05a1b4..94863ea 100644 --- a/example/simple-linear/phpa.yaml +++ b/example/simple-linear/phpa.yaml @@ -29,7 +29,7 @@ rules: verbs: - '*' --- -apiVersion: custompodautoscaler.com/v1alpha1 +apiVersion: custompodautoscaler.com/v1 kind: CustomPodAutoscaler metadata: name: simple-linear-example @@ -44,6 +44,7 @@ spec: apiVersion: apps/v1 kind: Deployment name: php-apache + provisionRole: false config: - name: minReplicas value: "1"