Skip to content

Commit

Permalink
feat: Add IP Range resource type
Browse files Browse the repository at this point in the history
  • Loading branch information
amhn committed Sep 10, 2022
1 parent f1079fd commit 35d31a6
Show file tree
Hide file tree
Showing 3 changed files with 447 additions and 0 deletions.
54 changes: 54 additions & 0 deletions examples/resources/netbox_ipam_ip_range/resource.tf
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
resource "netbox_ipam_ip_range" "range_test" {
start_address = "192.168.56.1/24"
end_address = "192.168.56.100/24"
description = "Range created by terraform"
role_id = data.netbox_ipam_roles.vlan_role_production.id
status = "active"

tag {
name = "tag1"
slug = "tag1"
}

custom_field {
name = "cf_boolean"
type = "boolean"
value = "true"
}

custom_field {
name = "cf_date"
type = "date"
value = "2020-12-25"
}

custom_field {
name = "cf_text"
type = "text"
value = "some text"
}

custom_field {
name = "cf_integer"
type = "integer"
value = "10"
}

custom_field {
name = "cf_selection"
type = "selection"
value = "1"
}

custom_field {
name = "cf_url"
type = "url"
value = "https://github.com"
}

custom_field {
name = "cf_multiple_selection"
type = "multiple"
value = "0,1"
}
}
1 change: 1 addition & 0 deletions netbox/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ func Provider() *schema.Provider {
ResourcesMap: map[string]*schema.Resource{
"netbox_ipam_aggregate": resourceNetboxIpamAggregate(),
"netbox_ipam_ip_addresses": resourceNetboxIpamIPAddresses(),
"netbox_ipam_ip_range": resourceNetboxIpamIPRange(),
"netbox_ipam_prefix": resourceNetboxIpamPrefix(),
"netbox_ipam_service": resourceNetboxIpamService(),
"netbox_ipam_vlan": resourceNetboxIpamVlan(),
Expand Down
Loading

0 comments on commit 35d31a6

Please sign in to comment.