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

Added missing public_ip_addresses property to api_management #2310

Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions azurerm/data_source_api_management.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,14 @@ func dataSourceApiManagementService() *schema.Resource {

"location": locationForDataSourceSchema(),

"public_ip_addresses": {
Type: schema.TypeList,
Computed: true,
Elem: &schema.Schema{
Type: schema.TypeString,
},
},

"publisher_name": {
Type: schema.TypeString,
Computed: true,
Expand Down
1 change: 1 addition & 0 deletions azurerm/data_source_api_management_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ func TestAccDataSourceAzureRMApiManagement_basic(t *testing.T) {
resource.TestCheckResourceAttr(dataSourceName, "sku.0.capacity", "1"),
resource.TestCheckResourceAttr(dataSourceName, "sku.0.name", "Developer"),
resource.TestCheckResourceAttr(dataSourceName, "tags.%", "0"),
resource.TestCheckResourceAttrSet(dataSourceName, "public_ip_addresses"),
vidarw marked this conversation as resolved.
Show resolved Hide resolved
),
},
},
Expand Down
8 changes: 8 additions & 0 deletions azurerm/resource_arm_api_management.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,14 @@ func resourceArmApiManagementService() *schema.Resource {

"location": locationSchema(),

"public_ip_addresses": {
Type: schema.TypeList,
Computed: true,
Elem: &schema.Schema{
Type: schema.TypeString,
},
},

"publisher_name": {
Type: schema.TypeString,
Required: true,
Expand Down
3 changes: 2 additions & 1 deletion azurerm/resource_arm_api_management_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,15 @@ func TestAccAzureRMApiManagement_complete(t *testing.T) {
Check: resource.ComposeTestCheckFunc(
testCheckAzureRMApiManagementExists(resourceName),
resource.TestCheckResourceAttr(resourceName, "tags.Acceptance", "Test"),
resource.TestCheckResourceAttrSet(resourceName, "public_ip_addresses"),
vidarw marked this conversation as resolved.
Show resolved Hide resolved
),
},
{
ResourceName: resourceName,
ImportState: true,
ImportStateVerify: true,
ImportStateVerifyIgnore: []string{
"certificate", // not returned from API, sensitive
"certificate", // not returned from API, sensitive
"hostname_configuration.0.portal.0.certificate", // not returned from API, sensitive
"hostname_configuration.0.portal.0.certificate_password", // not returned from API, sensitive
"hostname_configuration.0.proxy.0.certificate", // not returned from API, sensitive
Expand Down
2 changes: 2 additions & 0 deletions website/docs/d/api_management.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ output "api_management_id" {

* `portal_url` - The URL of the Publisher Portal.

* `public_ip_adresses` - The Public IP adresses of the API Management Service.
vidarw marked this conversation as resolved.
Show resolved Hide resolved
vidarw marked this conversation as resolved.
Show resolved Hide resolved

* `publisher_name` - The name of the Publisher/Company of the API Management Service.

* `publisher_email` - The email of Publisher/Company of the API Management Service.
Expand Down
2 changes: 2 additions & 0 deletions website/docs/r/api_management.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,8 @@ In addition to all arguments above, the following attributes are exported:

* `portal_url` - The URL for the Publisher Portal associated with this API Management service.

* `public_ip_adresses` - The Public IP adresses of the API Management Service.
vidarw marked this conversation as resolved.
Show resolved Hide resolved

* `scm_url` - The URL for the SCM (Source Code Management) Endpoint associated with this API Management service.

* `identity` - An `identity` block as defined below.
Expand Down