forked from LaconicNetwork/kompose
fix EOF, DefaultMaxReplicas set to 3, extended user guide about hpa, more tests
add warning in situations like: - maxreplicas < minreplicas - value from label < 0 - validate percentage in cpu, memory metrics
This commit is contained in:
@@ -343,4 +343,4 @@ convert::expect_success "$os_cmd" "$os_output" || exit 1
|
||||
# Test HPA
|
||||
k8s_cmd="kompose -f $KOMPOSE_ROOT/script/test/fixtures/hpa/compose.yaml convert --stdout --with-kompose-annotation=false"
|
||||
k8s_output="$KOMPOSE_ROOT/script/test/fixtures/hpa/output-k8s.yaml"
|
||||
convert::expect_success "$k8s_cmd" "$k8s_output" || exit 1
|
||||
convert::expect_success "$k8s_cmd" "$k8s_output" || exit 1
|
||||
|
||||
+4
-3
@@ -4,6 +4,7 @@ services:
|
||||
image: nginx
|
||||
labels:
|
||||
kompose.hpa.cpu: 50
|
||||
kompose.hap.memory: 70
|
||||
kompose.hap.replicas.min: 1
|
||||
kompose.hap.replicas.max: 10
|
||||
kompose.hpa.memory: 70
|
||||
kompose.hpa.replicas.min: 1
|
||||
kompose.hpa.replicas.max: 10
|
||||
|
||||
|
||||
+2
-1
@@ -45,4 +45,5 @@ spec:
|
||||
scaleTargetRef:
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
name: web
|
||||
name: web
|
||||
|
||||
|
||||
Reference in New Issue
Block a user