diff --git a/argocd/applications/metallb-application.yaml b/argocd/applications/metallb-application.yaml new file mode 100644 index 0000000..735b8b1 --- /dev/null +++ b/argocd/applications/metallb-application.yaml @@ -0,0 +1,23 @@ +# Declare the argocd application application applying the argocd directory +# content to the argocd cluster +apiVersion: argoproj.io/v1alpha1 +kind: Application +metadata: + name: argocd-metallb-application + namespace: argocd +spec: + project: default # Todo define a project to limit the deployment types + source: + chart: metallb + repoURL: https://metallb.github.io/metallb + targetRevision: 0.13.5 + helm: + releaseName: metallb + destination: + server: https://kubernetes.default.svc + namespace: metallb + syncPolicy: + automated: + prune: true + selfHeal: true + allowEmpty: false diff --git a/argocd/metallb-ip-pool.yaml b/argocd/metallb-ip-pool.yaml new file mode 100644 index 0000000..ac07a3b --- /dev/null +++ b/argocd/metallb-ip-pool.yaml @@ -0,0 +1,30 @@ +--- +apiVersion: metallb.io/v1beta1 +kind: IPAddressPool +metadata: + name: argocd-pool + namespace: metallb +spec: + addresses: + - 192.168.50.42/32 +--- +apiVersion: metallb.io/v1beta1 +kind: L2Advertisement +metadata: + name: l2-advertisement + namespace: metallb +--- +apiVersion: v1 +kind: Service +metadata: + name: ingress-lb + namespace: ingress-nginx + # annotations: + # metallb.universe.tf/address-pool: production-public-ips +spec: + ports: + - port: 80 + targetPort: 8080 + selector: + app: default-http-backend + type: LoadBalancer diff --git a/argocd/namespaces.yaml b/argocd/namespaces.yaml new file mode 100644 index 0000000..47bb057 --- /dev/null +++ b/argocd/namespaces.yaml @@ -0,0 +1,5 @@ +# Namespace dedicated to the swh elastic environment +apiVersion: v1 +kind: Namespace +metadata: + name: metallb