From fc8674d56608c57197448634e56c311e93b09695 Mon Sep 17 00:00:00 2001 From: Sofus Albertsen Date: Wed, 6 Sep 2023 12:34:35 +0200 Subject: [PATCH] Updating linter as well for Ingress --- .test/lint_kube.sh | 4 ++-- deployments-ingress.md | 2 +- deployments-ingress/done/frontend-ingress.yaml | 8 +++++--- deployments-ingress/start/frontend-ingress.yaml | 5 +++-- 4 files changed, 11 insertions(+), 8 deletions(-) diff --git a/.test/lint_kube.sh b/.test/lint_kube.sh index d8926ff..9dc28d4 100644 --- a/.test/lint_kube.sh +++ b/.test/lint_kube.sh @@ -5,8 +5,8 @@ KUBERNETES_RESOURCE_FILES=$(find * -type f \( -iname '*.yml' -or -iname '*.yaml' \) -and ! \( -iname "helmfile.yaml" -or -iname "values-*.yaml" -or -iname "*docker-compose*" \)) excludes=( - deployments-loadbalancing/start/frontend-deployment.yaml - deployments-loadbalancing/start/backend-deployment.yaml + deployments-ingress/start/frontend-deployment.yaml + deployments-ingress/start/backend-deployment.yaml manifests/start/frontend-pod.yaml services/start/backend-svc.yaml services/start/frontend-svc.yaml diff --git a/deployments-ingress.md b/deployments-ingress.md index 8df3344..08bfa17 100644 --- a/deployments-ingress.md +++ b/deployments-ingress.md @@ -481,7 +481,7 @@ kubectl delete -f backend-svc.yaml kubectl delete -f frontend-ingress.yaml ``` -> :bulb: If you ever want to delete all resources from a particular directory, you can use a shell wildcard: `kubectl delete -f *.yaml` which will point at **all** `.yaml` files in that directory! +> :bulb: If you ever want to delete all resources from a particular directory, you can use: `kubectl delete -f .` which will point at **all** files in that directory! # Extra Exercise diff --git a/deployments-ingress/done/frontend-ingress.yaml b/deployments-ingress/done/frontend-ingress.yaml index 4bf8419..d74d281 100644 --- a/deployments-ingress/done/frontend-ingress.yaml +++ b/deployments-ingress/done/frontend-ingress.yaml @@ -2,20 +2,22 @@ apiVersion: networking.k8s.io/v1 kind: Ingress metadata: annotations: - #internet facing + # These annotations are required to use ALB Ingress Controller alb.ingress.kubernetes.io/scheme: internet-facing kubernetes.io/ingress.class: alb alb.ingress.kubernetes.io/listen-ports: '[{"HTTPS":443}]' name: frontend-ingress spec: rules: - - host: frontend-1.prosa.eficode.academy + # you need to change the host to match your own + - host: quotes-sal.prosa.eficode.academy http: paths: - pathType: Prefix path: "/" backend: service: + # change this to match your service name name: frontend port: - number: 80 \ No newline at end of file + number: 5000 \ No newline at end of file diff --git a/deployments-ingress/start/frontend-ingress.yaml b/deployments-ingress/start/frontend-ingress.yaml index 00c4feb..15816db 100644 --- a/deployments-ingress/start/frontend-ingress.yaml +++ b/deployments-ingress/start/frontend-ingress.yaml @@ -10,7 +10,7 @@ metadata: spec: rules: # you need to change the host to match your own - - host: frontend-..eficode.academy + - host: quotes-..eficode.academy http: paths: - pathType: Prefix @@ -20,4 +20,5 @@ spec: # change this to match your service name name: port: - number: 80 \ No newline at end of file + # this is the port your service is listening on + number: 5000 \ No newline at end of file