mirror of
https://github.com/go-acme/lego.git
synced 2025-01-20 21:18:36 +02:00
added authorization to dns zones client (#428)
This commit is contained in:
parent
49b9503635
commit
addee401b0
@ -125,11 +125,10 @@ func (c *DNSProvider) getHostedZoneID(fqdn string) (string, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Now we want to to Azure and get the zone.
|
// Now we want to to Azure and get the zone.
|
||||||
dc := dns.NewZonesClient(c.subscriptionId)
|
|
||||||
|
|
||||||
rsc := dns.NewRecordSetsClient(c.subscriptionId)
|
|
||||||
spt, err := c.newServicePrincipalTokenFromCredentials(azure.PublicCloud.ResourceManagerEndpoint)
|
spt, err := c.newServicePrincipalTokenFromCredentials(azure.PublicCloud.ResourceManagerEndpoint)
|
||||||
rsc.Authorizer = autorest.NewBearerAuthorizer(spt)
|
|
||||||
|
dc := dns.NewZonesClient(c.subscriptionId)
|
||||||
|
dc.Authorizer = autorest.NewBearerAuthorizer(spt)
|
||||||
|
|
||||||
zone, err := dc.Get(c.resourceGroup, acme.UnFqdn(authZone))
|
zone, err := dc.Get(c.resourceGroup, acme.UnFqdn(authZone))
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user