From f5473b3c2bbc7a6a6d0758a46496dd6f1946d32d Mon Sep 17 00:00:00 2001 From: gifrerenom <lluis.gifre@cttc.es> Date: Fri, 7 Jul 2023 17:55:19 +0000 Subject: [PATCH] Pre-merge code cleanup --- manifests/contextservice.yaml | 49 +++++++++++++++++----------------- manifests/deviceservice.yaml | 7 +++-- manifests/pathcompservice.yaml | 44 +++++++++++++++--------------- manifests/serviceservice.yaml | 44 +++++++++++++++--------------- manifests/sliceservice.yaml | 44 +++++++++++++++--------------- 5 files changed, 93 insertions(+), 95 deletions(-) diff --git a/manifests/contextservice.yaml b/manifests/contextservice.yaml index 659ff7b8d..ab8ccc521 100644 --- a/manifests/contextservice.yaml +++ b/manifests/contextservice.yaml @@ -23,9 +23,8 @@ spec: #replicas: 1 template: metadata: - # Deactivated linkerd for the Hackfest - #annotations: - # config.linkerd.io/skip-outbound-ports: "4222" + annotations: + config.linkerd.io/skip-outbound-ports: "4222" labels: app: contextservice spec: @@ -80,25 +79,25 @@ spec: protocol: TCP port: 9192 targetPort: 9192 -#--- -#apiVersion: autoscaling/v2 -#kind: HorizontalPodAutoscaler -#metadata: -# name: contextservice-hpa -#spec: -# scaleTargetRef: -# apiVersion: apps/v1 -# kind: Deployment -# name: contextservice -# minReplicas: 1 -# maxReplicas: 20 -# metrics: -# - type: Resource -# resource: -# name: cpu -# target: -# type: Utilization -# averageUtilization: 80 -# #behavior: -# # scaleDown: -# # stabilizationWindowSeconds: 30 +--- +apiVersion: autoscaling/v2 +kind: HorizontalPodAutoscaler +metadata: + name: contextservice-hpa +spec: + scaleTargetRef: + apiVersion: apps/v1 + kind: Deployment + name: contextservice + minReplicas: 1 + maxReplicas: 20 + metrics: + - type: Resource + resource: + name: cpu + target: + type: Utilization + averageUtilization: 80 + #behavior: + # scaleDown: + # stabilizationWindowSeconds: 30 diff --git a/manifests/deviceservice.yaml b/manifests/deviceservice.yaml index 74c58b83d..4bf4d6247 100644 --- a/manifests/deviceservice.yaml +++ b/manifests/deviceservice.yaml @@ -23,10 +23,9 @@ spec: replicas: 1 template: metadata: - # Deactivated linkerd for the Hackfest - #annotations: - # # Required for IETF L2VPN SBI when both parent and child run in same K8s cluster with Linkerd - # config.linkerd.io/skip-outbound-ports: "8002" + annotations: + # Required for IETF L2VPN SBI when both parent and child run in same K8s cluster with Linkerd + config.linkerd.io/skip-outbound-ports: "8002" labels: app: deviceservice spec: diff --git a/manifests/pathcompservice.yaml b/manifests/pathcompservice.yaml index 8aaf99dcb..2fae0c8f2 100644 --- a/manifests/pathcompservice.yaml +++ b/manifests/pathcompservice.yaml @@ -98,25 +98,25 @@ spec: protocol: TCP port: 9192 targetPort: 9192 -#--- -#apiVersion: autoscaling/v2 -#kind: HorizontalPodAutoscaler -#metadata: -# name: pathcompservice-hpa -#spec: -# scaleTargetRef: -# apiVersion: apps/v1 -# kind: Deployment -# name: pathcompservice -# minReplicas: 1 -# maxReplicas: 20 -# metrics: -# - type: Resource -# resource: -# name: cpu -# target: -# type: Utilization -# averageUtilization: 80 -# #behavior: -# # scaleDown: -# # stabilizationWindowSeconds: 30 +--- +apiVersion: autoscaling/v2 +kind: HorizontalPodAutoscaler +metadata: + name: pathcompservice-hpa +spec: + scaleTargetRef: + apiVersion: apps/v1 + kind: Deployment + name: pathcompservice + minReplicas: 1 + maxReplicas: 20 + metrics: + - type: Resource + resource: + name: cpu + target: + type: Utilization + averageUtilization: 80 + #behavior: + # scaleDown: + # stabilizationWindowSeconds: 30 diff --git a/manifests/serviceservice.yaml b/manifests/serviceservice.yaml index 99f8f45a6..6143740e8 100644 --- a/manifests/serviceservice.yaml +++ b/manifests/serviceservice.yaml @@ -70,25 +70,25 @@ spec: protocol: TCP port: 9192 targetPort: 9192 -#--- -#apiVersion: autoscaling/v2 -#kind: HorizontalPodAutoscaler -#metadata: -# name: serviceservice-hpa -#spec: -# scaleTargetRef: -# apiVersion: apps/v1 -# kind: Deployment -# name: serviceservice -# minReplicas: 1 -# maxReplicas: 20 -# metrics: -# - type: Resource -# resource: -# name: cpu -# target: -# type: Utilization -# averageUtilization: 80 -# #behavior: -# # scaleDown: -# # stabilizationWindowSeconds: 30 +--- +apiVersion: autoscaling/v2 +kind: HorizontalPodAutoscaler +metadata: + name: serviceservice-hpa +spec: + scaleTargetRef: + apiVersion: apps/v1 + kind: Deployment + name: serviceservice + minReplicas: 1 + maxReplicas: 20 + metrics: + - type: Resource + resource: + name: cpu + target: + type: Utilization + averageUtilization: 80 + #behavior: + # scaleDown: + # stabilizationWindowSeconds: 30 diff --git a/manifests/sliceservice.yaml b/manifests/sliceservice.yaml index 5ea63ad0c..7f4d022b3 100644 --- a/manifests/sliceservice.yaml +++ b/manifests/sliceservice.yaml @@ -75,25 +75,25 @@ spec: protocol: TCP port: 9192 targetPort: 9192 -#--- -#apiVersion: autoscaling/v2 -#kind: HorizontalPodAutoscaler -#metadata: -# name: sliceservice-hpa -#spec: -# scaleTargetRef: -# apiVersion: apps/v1 -# kind: Deployment -# name: sliceservice -# minReplicas: 1 -# maxReplicas: 20 -# metrics: -# - type: Resource -# resource: -# name: cpu -# target: -# type: Utilization -# averageUtilization: 80 -# #behavior: -# # scaleDown: -# # stabilizationWindowSeconds: 30 +--- +apiVersion: autoscaling/v2 +kind: HorizontalPodAutoscaler +metadata: + name: sliceservice-hpa +spec: + scaleTargetRef: + apiVersion: apps/v1 + kind: Deployment + name: sliceservice + minReplicas: 1 + maxReplicas: 20 + metrics: + - type: Resource + resource: + name: cpu + target: + type: Utilization + averageUtilization: 80 + #behavior: + # scaleDown: + # stabilizationWindowSeconds: 30 -- GitLab