Skip to content

Commit

Permalink
Update examples to CPA CRD v1 (#30)
Browse files Browse the repository at this point in the history
  • Loading branch information
jthomperoo authored Jul 18, 2020
1 parent 60d5d35 commit 4863445
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
5 changes: 3 additions & 2 deletions docs/reference/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -22,6 +22,7 @@ spec:
apiVersion: apps/v1
kind: Deployment
name: php-apache
provisionRole: false
config:
- name: minReplicas
value: "1"
Expand Down Expand Up @@ -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.
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.
3 changes: 2 additions & 1 deletion example/persistent-linear/phpa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -79,6 +79,7 @@ spec:
apiVersion: apps/v1
kind: Deployment
name: php-apache
provisionRole: false
config:
- name: minReplicas
value: "1"
Expand Down
5 changes: 3 additions & 2 deletions example/simple-holt-winters/phpa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ rules:
verbs:
- '*'
---
apiVersion: custompodautoscaler.com/v1alpha1
apiVersion: custompodautoscaler.com/v1
kind: CustomPodAutoscaler
metadata:
name: simple-holt-winters-example
Expand All @@ -44,6 +44,7 @@ spec:
apiVersion: apps/v1
kind: Deployment
name: php-apache
provisionRole: false
config:
- name: minReplicas
value: "1"
Expand Down Expand Up @@ -75,4 +76,4 @@ spec:
- name: startTime
value: "60000"
- name: downscaleStabilization
value: "30"
value: "30"
3 changes: 2 additions & 1 deletion example/simple-linear/phpa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ rules:
verbs:
- '*'
---
apiVersion: custompodautoscaler.com/v1alpha1
apiVersion: custompodautoscaler.com/v1
kind: CustomPodAutoscaler
metadata:
name: simple-linear-example
Expand All @@ -44,6 +44,7 @@ spec:
apiVersion: apps/v1
kind: Deployment
name: php-apache
provisionRole: false
config:
- name: minReplicas
value: "1"
Expand Down

0 comments on commit 4863445

Please sign in to comment.