msi

package
v0.0.0-...-19353be Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 9, 2021 License: Apache-2.0 Imports: 7 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Compute

type Compute struct {
	Compute MetaData `json:"compute"`
}

type MetaData

type MetaData struct {
	SubscriptionId    string `json:"subscriptionId"`
	VMName            string `json:"name"`
	VMssName          string `json:"vmScaleSetName"`
	ResourceGroupName string `json:"resourceGroupName"`
}

func GetInstanceMetadata

func GetInstanceMetadata() (MetaData, error)

GetInstanceMetadata ()

*Calls the Azure in-VM Instance Metadata service and returns the results to the caller

type MsiToken

type MsiToken struct {
	AccessToken  string `json:"access_token"`
	RefreshToken string `json:"refresh_token"`
	ExpiresIn    string `json:"expires_in"`
	ExpiresOn    string `json:"expires_on"`
	NotBefore    string `json:"not_before"`
	Resource     string `json:"resource"`
	TokenType    string `json:"token_type"`
}

MsiToken ()

*Encapsulates a token retrieved by the MSI extension on the local machine

func GetMsiToken

func GetMsiToken() (token MsiToken, err error)

GetMsiToken ()

*Uses the Managed Service Identity Extension to retrieve a token that allows the VM to call into
*the Azure Resource Manager APIs

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL