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

azurerm_cdn_endpoint extensions #967

Merged
merged 8 commits into from
Mar 13, 2018
Merged
Show file tree
Hide file tree
Changes from all 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
19 changes: 9 additions & 10 deletions azurerm/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,9 @@ type ArmClient struct {
servicePrincipalsClient graphrbac.ServicePrincipalsClient

// CDN
cdnProfilesClient cdn.ProfilesClient
cdnEndpointsClient cdn.EndpointsClient
cdnCustomDomainsClient cdn.CustomDomainsClient
cdnEndpointsClient cdn.EndpointsClient
cdnProfilesClient cdn.ProfilesClient

// Compute
availSetClient compute.AvailabilitySetsClient
Expand Down Expand Up @@ -425,18 +426,16 @@ func (c *ArmClient) registerAuthentication(endpoint, graphEndpoint, subscription
}

func (c *ArmClient) registerCDNClients(endpoint, subscriptionId string, auth autorest.Authorizer, sender autorest.Sender) {
customDomainsClient := cdn.NewCustomDomainsClientWithBaseURI(endpoint, subscriptionId)
c.configureClient(&customDomainsClient.Client, auth)
c.cdnCustomDomainsClient = customDomainsClient

endpointsClient := cdn.NewEndpointsClientWithBaseURI(endpoint, subscriptionId)
setUserAgent(&endpointsClient.Client)
endpointsClient.Authorizer = auth
endpointsClient.Sender = sender
endpointsClient.SkipResourceProviderRegistration = c.skipProviderRegistration
c.configureClient(&endpointsClient.Client, auth)
c.cdnEndpointsClient = endpointsClient

profilesClient := cdn.NewProfilesClientWithBaseURI(endpoint, subscriptionId)
setUserAgent(&profilesClient.Client)
profilesClient.Authorizer = auth
profilesClient.Sender = sender
profilesClient.SkipResourceProviderRegistration = c.skipProviderRegistration
c.configureClient(&profilesClient.Client, auth)
c.cdnProfilesClient = profilesClient
}

Expand Down
Loading