This commit is contained in:
2025-09-26 11:55:32 -05:00
parent e7f8fd2ccd
commit 6107e474c1
34 changed files with 927 additions and 462 deletions

View File

@@ -0,0 +1,8 @@
resource "unifi_user" "{{ inventory_hostname }}" {
mac = "{{ vm_mac_address }}"
name = "{{ inventory_hostname }}"
# note = "my note"
fixed_ip = "{{ ip_address }}"
allow_existing = true
}

View File

@@ -0,0 +1,22 @@
// Configure the unifi provider
terraform {
required_providers {
unifi = {
source = "paultyng/unifi"
version = "0.41.0"
}
}
}
provider "unifi" {
username = "terraform" # optionally use UNIFI_USERNAME env var
password = "{{ vault_unifi_password }}" # optionally use UNIFI_PASSWORD env var
api_url = "https://192.168.1.1" # optionally use UNIFI_API env var
# you may need to allow insecure TLS communications unless you have configured
# certificates for your controller
allow_insecure = "true" # optionally use UNIFI_INSECURE env var
# if you are not configuring the default site, you can change the site
# site = "world-drive" # or optionally use UNIFI_SITE env var
}