- provider: GCP
- machine config:
n1-standard-2
- Cluster Autoscaling: enabled to max 4 worker nodes min 1 worker node
using kyma-cli to install kyma-lite. refer the component file used as input for installation. (filename: serverless.yaml)
kyma install -c ./serverless.yaml
- Cluster Essentials
- istio
- xip-patch
- core
- serverless
- 7 mins 6 seconds
SUCCESS
kubectl apply -f - <<EOF
apiVersion: serverless.kyma-project.io/v1alpha1
kind: Function
metadata:
name: test-fn
spec:
buildResources:
limits:
cpu: 1100m
memory: 1100Mi
requests:
cpu: 700m
memory: 700Mi
deps: "{ \n \"name\": \"hilly-road\",\n \"version\": \"1.0.0\",\n \"dependencies\":
{}\n}"
maxReplicas: 1
minReplicas: 1
resources:
limits:
cpu: 100m
memory: 128Mi
requests:
cpu: 50m
memory: 64Mi
runtime: nodejs12
source: "module.exports = { \n main: function (event, context) {\n return \"Hello
World!\";\n }\n}"
---
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: vs-func
spec:
gateways:
- kyma-gateway.kyma-system.svc.cluster.local
hosts:
- test.aj-ser1.cf-kyma-k8.shoot.canary.k8s-hana.ondemand.com
http:
- match:
- uri:
regex: /.*
route:
- destination:
host: test-fn
port:
number: 80
weight: 100
EOF
- As soon as a function is deployed, cluster is scaled to 2 worker nodes, probably due to function build job resource utilization.
- Resource Utilisation on one running function under no load.
╰─ k top node ─╯
NAME CPU(cores) CPU% MEMORY(bytes) MEMORY%
shoot--cf-kyma-k8--aj-ser1-worker-jinug-z1-7dbf7-84mz6 205m 10% 1320Mi 21%
shoot--cf-kyma-k8--aj-ser1-worker-jinug-z1-7dbf7-zdl7l 336m 17% 1996Mi 32%
- kyma installation using cli usually retreives an
admin-user
secret, but due to missingcluster-users
chart this secret was not created. (Can be mitigated by not using kyma-cli, or adding the secret in another chart, or installcluster-users
. - DNSEntry resource had to be created manually sometimes to make virtualservice host map to the istio-ingressgateway.