Skip to content

Commit

Permalink
feat: optional csi-driver deployment (#51)
Browse files Browse the repository at this point in the history
Closes #50

Co-authored-by: simonhammes <[email protected]>
  • Loading branch information
simonhammes and simonhammes authored Oct 1, 2024
1 parent f0ff628 commit 331c11b
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
13 changes: 13 additions & 0 deletions main-setup.tf
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,19 @@ resource "helm_release" "hcloud_cloud_controller_manager" {
}
}

resource "helm_release" "hcloud_csi_driver" {
count = var.deploy_csi_driver ? 1 : 0

depends_on = [kubernetes_secret_v1.hcloud_token]

name = "hcloud-csi"
chart = "hcloud-csi"
repository = "https://charts.hetzner.cloud"
namespace = "kube-system"
version = "2.9.0"
wait = true
}

resource "helm_release" "docker_registry" {
depends_on = [helm_release.cilium]

Expand Down
5 changes: 5 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ variable "deploy_hccm" {
type = bool
default = true
}
variable "deploy_csi_driver" {
description = "Deploy the csi-driver through Helm"
type = bool
default = false
}
variable "use_cloud_routes" {
description = "Use the Hetzner Cloud network routes for Pod traffic. Enables hcloud-cloud-controller-manager routes controller and Cilium native routing. Does not work with Robot servers."
type = bool
Expand Down

0 comments on commit 331c11b

Please sign in to comment.