Skip to content

Commit

Permalink
WIP: New Resource: azurerm_app_service_environment
Browse files Browse the repository at this point in the history
  • Loading branch information
tombuildsstuff committed Feb 21, 2018
1 parent d857cb5 commit 5fbe018
Show file tree
Hide file tree
Showing 4 changed files with 709 additions and 2 deletions.
12 changes: 10 additions & 2 deletions azurerm/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,8 +177,9 @@ type ArmClient struct {
trafficManagerEndpointsClient trafficmanager.EndpointsClient

// Web
appServicePlansClient web.AppServicePlansClient
appServicesClient web.AppsClient
appServiceEnvironmentsClient web.AppServiceEnvironmentsClient
appServicePlansClient web.AppServicePlansClient
appServicesClient web.AppsClient
}

func (c *ArmClient) configureClient(client *autorest.Client, auth autorest.Authorizer) {
Expand Down Expand Up @@ -808,6 +809,13 @@ func (c *ArmClient) registerTrafficManagerClients(endpoint, subscriptionId strin
}

func (c *ArmClient) registerWebClients(endpoint, subscriptionId string, auth autorest.Authorizer) {
appServiceEnvironmentsClient := web.NewAppServiceEnvironmentsClientWithBaseURI(endpoint, subscriptionId)
c.configureClient(&appServiceEnvironmentsClient.Client, auth)
// App Service Environments are s-l-o-w.
appServiceEnvironmentsClient.RetryAttempts = 300
appServiceEnvironmentsClient.RetryDuration = 60 * time.Second
c.appServiceEnvironmentsClient = appServiceEnvironmentsClient

appServicePlansClient := web.NewAppServicePlansClientWithBaseURI(endpoint, subscriptionId)
c.configureClient(&appServicePlansClient.Client, auth)
c.appServicePlansClient = appServicePlansClient
Expand Down
1 change: 1 addition & 0 deletions azurerm/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ func Provider() terraform.ResourceProvider {
"azurerm_application_gateway": resourceArmApplicationGateway(),
"azurerm_application_insights": resourceArmApplicationInsights(),
"azurerm_app_service": resourceArmAppService(),
"azurerm_app_service_environment": resourceArmAppServiceEnvironment(),
"azurerm_app_service_plan": resourceArmAppServicePlan(),
"azurerm_app_service_active_slot": resourceArmAppServiceActiveSlot(),
"azurerm_app_service_slot": resourceArmAppServiceSlot(),
Expand Down
Loading

0 comments on commit 5fbe018

Please sign in to comment.