Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated maximum volume size to 10240 #1540

Merged
merged 1 commit into from
Nov 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions agents.tf
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ resource "null_resource" "agents" {
}

resource "hcloud_volume" "longhorn_volume" {
for_each = { for k, v in local.agent_nodes : k => v if((v.longhorn_volume_size >= 10) && (v.longhorn_volume_size <= 10000) && var.enable_longhorn) }
for_each = { for k, v in local.agent_nodes : k => v if((v.longhorn_volume_size >= 10) && (v.longhorn_volume_size <= 10240) && var.enable_longhorn) }

labels = {
provisioner = "terraform"
Expand All @@ -146,7 +146,7 @@ resource "hcloud_volume" "longhorn_volume" {
}

resource "null_resource" "configure_longhorn_volume" {
for_each = { for k, v in local.agent_nodes : k => v if((v.longhorn_volume_size >= 10) && (v.longhorn_volume_size <= 10000) && var.enable_longhorn) }
for_each = { for k, v in local.agent_nodes : k => v if((v.longhorn_volume_size >= 10) && (v.longhorn_volume_size <= 10240) && var.enable_longhorn) }

triggers = {
agent_id = module.agents[each.key].id
Expand Down
4 changes: 2 additions & 2 deletions kube.tf.example
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ module "kube-hetzner" {
taints = [],
count = 1

# In the case of using Longhorn, you can use Hetzner volumes instead of using the node's own storage by specifying a value from 10 to 10000 (in GB)
# In the case of using Longhorn, you can use Hetzner volumes instead of using the node's own storage by specifying a value from 10 to 10240 (in GB)
# It will create one volume per node in the nodepool, and configure Longhorn to use them.
# Something worth noting is that Volume storage is slower than node storage, which is achieved by not mentioning longhorn_volume_size or setting it to 0.
# So for something like DBs, you definitely want node storage, for other things like backups, volume storage is fine, and cheaper.
Expand Down Expand Up @@ -455,7 +455,7 @@ module "kube-hetzner" {
# After the cluster is deployed, you can always use HelmChartConfig definition to tweak the configuration.

# Also, you can choose to use a Hetzner volume with Longhorn. By default, it will use the nodes own storage space, but if you add an attribute of
# longhorn_volume_size (⚠️ not a variable, just a possible agent nodepool attribute) with a value between 10 and 10000 GB to your agent nodepool definition, it will create and use the volume in question.
# longhorn_volume_size (⚠️ not a variable, just a possible agent nodepool attribute) with a value between 10 and 10240 GB to your agent nodepool definition, it will create and use the volume in question.
# See the agent nodepool section for an example of how to do that.

# To disable Hetzner CSI storage, you can set the following to "true", default is "false".
Expand Down