diff --git a/cache-infrastructure/index.ts b/cache-infrastructure/index.ts index 0cc15a4..c627649 100644 --- a/cache-infrastructure/index.ts +++ b/cache-infrastructure/index.ts @@ -1,7 +1,7 @@ import { Construct } from "constructs"; import { TerraformStack } from "cdktf"; import { KubernetesProvider } from "@cdktf/provider-kubernetes/lib/provider"; -import { NixCache } from "./nixcache"; +import { NixCache } from "./nix"; export class CacheInfrastructure extends TerraformStack { constructor(scope: Construct, id: string) { diff --git a/cache-infrastructure/nixcache/index.ts b/cache-infrastructure/nix/index.ts similarity index 94% rename from cache-infrastructure/nixcache/index.ts rename to cache-infrastructure/nix/index.ts index b058da4..407c217 100644 --- a/cache-infrastructure/nixcache/index.ts +++ b/cache-infrastructure/nix/index.ts @@ -6,7 +6,7 @@ import { DeploymentV1 } from "@cdktf/provider-kubernetes/lib/deployment-v1"; import { KubernetesProvider } from "@cdktf/provider-kubernetes/lib/provider"; import { ServiceV1 } from "@cdktf/provider-kubernetes/lib/service-v1"; -import { IngressRoute, LonghornPvc } from "../../utils"; +import { PublicIngressRoute, LonghornPvc } from "../../utils"; export class NixCache extends Construct { constructor(scope: Construct, id: string, provider: KubernetesProvider) { @@ -119,14 +119,13 @@ export class NixCache extends Construct { }, }); - new IngressRoute(this, "ingress-route", { + new PublicIngressRoute(this, "ingress-route", { provider, + name: "nix-cache", namespace: "homelab", host: "nix.dogar.dev", serviceName: "nix-cache", servicePort: 80, - entryPoints: ["websecure"], - tlsSecretName: "nix-cache-tls", }); } } diff --git a/cache-infrastructure/nixcache/nginx.conf b/cache-infrastructure/nix/nginx.conf similarity index 100% rename from cache-infrastructure/nixcache/nginx.conf rename to cache-infrastructure/nix/nginx.conf