Homelab 3 - ArgoCD
ArgoCD
So, with cdk8s I have an execellent way to author my Kubernetes manifests. How do I deploy them?
The workflow is actually quite simple. I store my Kubernetes manifests in a GitHub repo and I point ArgoCD to it.
How do I configure ArgoCD? With cdk8s, of course:
import { import Chart
Chart } from "https://esm.sh/[email protected]";
import { import Application
Application } from "../../imports/argoproj.io.ts";
export function function createLamportApp(chart: Chart): any
createLamportApp(chart: Chart
chart: import Chart
Chart) {
return new import Application
Application(chart: Chart
chart, "lamport-app", {
metadata: {
name: string;
}
metadata: {
name: string
name: "lamport",
},
spec: {
project: string;
source: {
repoUrl: string;
path: string;
targetRevision: string;
};
destination: {
server: string;
namespace: string;
};
syncPolicy: {
automated: {};
syncOptions: string[];
};
}
spec: {
project: string
project: "default",
source: {
repoUrl: string;
path: string;
targetRevision: string;
}
source: {
repoUrl: string
repoUrl: "https://github.com/shepherdjerred/homelab",
path: string
path: "cdk8s/dist/",
targetRevision: string
targetRevision: "main",
},
destination: {
server: string;
namespace: string;
}
destination: {
server: string
server: "https://kubernetes.default.svc",
namespace: string
namespace: "lamport",
},
syncPolicy: {
automated: {};
syncOptions: string[];
}
syncPolicy: {
automated: {}
automated: {},
syncOptions: string[]
syncOptions: ["CreateNamespace=true"],
},
},
});
}