Documentation ¶
Overview ¶
Package helpers contains helper functions for working with Azure DNS.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateRecordName ¶
GenerateRecordName determines a DNS resource record name from a hostname and the zone name. It strips any trailing dots and optionally the zone name from the provided hostname. If the result would be the empty string, it instead returns "@", which corresponds to the apex of DNS zone.
func GetAuthorizer ¶
func GetAuthorizer(baseURI string) (authorizer *autorest.BearerAuthorizer, err error)
GetAuthorizer creates a BearerAuthorizer based on credentials retrieved from Viper. If credentials have not been provided, an error will be returned.
func NewRecordSetClient ¶
func NewRecordSetClient(baseURI string) (client dns.RecordSetsClient, err error)
NewRecordSetClient creates a new RecordSetsClient using the specified baseURI and attaches a BearerAuthorizer based on credentials provided either via an Azure SDK auth file, if present, or through any mechanism supported by Viper. If credentials have not been provided, an error will be returned.
Types ¶
This section is empty.