Make appdata and unraid smb modules to reduce duplication
This commit is contained in:
@@ -18,27 +18,9 @@ resource "nomad_variable" "postgres" {
|
||||
}
|
||||
}
|
||||
|
||||
resource "nomad_csi_volume_registration" "unraid_database_dump" {
|
||||
#Note: Before chaning the definition of this volume you need to stop the jobs that are using it
|
||||
depends_on = [data.nomad_plugin.smb]
|
||||
plugin_id = "smb"
|
||||
|
||||
volume_id = "unraid_database_dump"
|
||||
name = "unraid_database_dump"
|
||||
|
||||
external_id = "unraid_database_dump"
|
||||
|
||||
capability {
|
||||
access_mode = "single-node-writer"
|
||||
attachment_mode = "file-system"
|
||||
}
|
||||
|
||||
context = {
|
||||
source = "//betelgeuse-seven-unraid.lan/database-dump"
|
||||
}
|
||||
|
||||
secrets = {
|
||||
"username" = "nomad"
|
||||
"password" = data.sops_file.secrets.data["unraid.nomad"]
|
||||
}
|
||||
module "unraid_smb_database_dump" {
|
||||
source = "../modules/unraid_smb"
|
||||
name = "dump"
|
||||
id = "unraid_database_dump"
|
||||
share = "database-dump"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user