Add Unifi Network
This commit is contained in:
32
2-nomad-config/unifi.tf
Normal file
32
2-nomad-config/unifi.tf
Normal file
@@ -0,0 +1,32 @@
|
||||
|
||||
resource "nomad_job" "unifi_network" {
|
||||
jobspec = file("unifi.nomad.hcl")
|
||||
}
|
||||
|
||||
|
||||
resource "nomad_csi_volume_registration" "unraid_appdata_unifi_network" {
|
||||
# Note: Before changing 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_appdata_unifi_network"
|
||||
name = "unraid_appdata_unifi_network"
|
||||
|
||||
external_id = "unraid_appdata_unifi_network"
|
||||
|
||||
capability {
|
||||
access_mode = "single-node-writer"
|
||||
attachment_mode = "file-system"
|
||||
}
|
||||
|
||||
context = {
|
||||
source = "//192.168.1.192/appdata"
|
||||
subDir = "unifi-network" # Note: Needs to be manually created on the share
|
||||
}
|
||||
|
||||
secrets = {
|
||||
"username" = "nomad"
|
||||
"password" = data.sops_file.secrets.data["unraid.nomad"]
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user