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

Add Nameservers to Subnet structure #47

Merged
merged 1 commit into from
Jun 17, 2022
Merged

Add Nameservers to Subnet structure #47

merged 1 commit into from
Jun 17, 2022

Conversation

poulpreben
Copy link
Contributor

I've added Nameservers to go-phpipam-sdk, and added the corresponding enhancements to the Terraform provider structure. The result looks like this:

# data.phpipam_subnet.test:
data "phpipam_subnet" "test" {
    allow_ip_requests      = false
    create_ptr_records     = false
    description            = "NNN-126"
    description_match      = "NNN-126"
    display_hostnames      = false
    edit_date              = "2022-06-17 10:38:12"
    gateway                = {}
    gateway_id             = "714"
    host_discovery_enabled = false
    id                     = "135"
    include_in_ping        = false
    is_folder              = false
    is_full                = false
    linked_subnet_id       = 0
    location_id            = 0
    master_subnet_id       = 134
    nameserver_id          = 4
    nameservers            = {
        "description" = ""
        "editDate"    = ""
        "id"          = "4"
        "name"        = "External Nameservers"
        "namesrv1"    = "XXX.YYY.76.60;XXX.YYY.76.76"
        "permissions" = "1;3"
    }
    permissions            = jsonencode(
        {
            "2" = "3"
        }
    )
    scan_agent_id          = 0
    section_id             = 3
    show_name              = false
    subnet_address         = "XXX.YYY.79.0"
    subnet_id              = 135
    subnet_mask            = 26
    utilization_threshold  = 0
    vlan_id                = 54
    vrf_id                 = 0
}

As such, it is now possible to add the semicolon separated list of nameservers using data.phpipam_subnet.my_subnet.nameservers.namesrv1.

@lord-kyron lord-kyron merged commit 56d7359 into lord-kyron:master Jun 17, 2022
@lord-kyron
Copy link
Owner

Thank you @poulpreben

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants