Documentation ¶
Index ¶
- Constants
- func NormalizeAzureCloud(cloudName string) string
- func WriteToEnvStr(azureSettings *AzureSettings) []string
- type AzureCloudInfo
- type AzureCloudSettings
- type AzureSettings
- func (settings *AzureSettings) Clouds() []AzureCloudInfo
- func (settings *AzureSettings) CustomClouds() []AzureCloudInfo
- func (settings *AzureSettings) GetCloud(cloudName string) (*AzureCloudSettings, error)
- func (settings *AzureSettings) GetDefaultCloud() string
- func (settings *AzureSettings) SetCustomClouds(customCloudsJSON string) error
- type TokenEndpointSettings
- type WorkloadIdentitySettings
Constants ¶
View Source
const ( AzurePublic = "AzureCloud" AzureChina = "AzureChinaCloud" AzureUSGovernment = "AzureUSGovernment" AzureCustomized = "AzureCustomizedCloud" )
View Source
const ( AzureCloud = "GFAZPL_AZURE_CLOUD" AzureCustomCloudsConfig = "GFAZPL_AZURE_CLOUDS_CONFIG" AzureAuthEnabled = "GFAZPL_AZURE_AUTH_ENABLED" ManagedIdentityEnabled = "GFAZPL_MANAGED_IDENTITY_ENABLED" ManagedIdentityClientID = "GFAZPL_MANAGED_IDENTITY_CLIENT_ID" WorkloadIdentityEnabled = "GFAZPL_WORKLOAD_IDENTITY_ENABLED" WorkloadIdentityTenantID = "GFAZPL_WORKLOAD_IDENTITY_TENANT_ID" WorkloadIdentityClientID = "GFAZPL_WORKLOAD_IDENTITY_CLIENT_ID" WorkloadIdentityTokenFile = "GFAZPL_WORKLOAD_IDENTITY_TOKEN_FILE" UserIdentityEnabled = "GFAZPL_USER_IDENTITY_ENABLED" UserIdentityTokenURL = "GFAZPL_USER_IDENTITY_TOKEN_URL" UserIdentityClientID = "GFAZPL_USER_IDENTITY_CLIENT_ID" UserIdentityClientSecret = "GFAZPL_USER_IDENTITY_CLIENT_SECRET" UserIdentityAssertion = "GFAZPL_USER_IDENTITY_ASSERTION" UserIdentityFallbackCredentialsEnabled = "GFAZPL_USER_IDENTITY_FALLBACK_SERVICE_CREDENTIALS_ENABLED" AzureEntraPasswordCredentialsEnabled = "GFAZPL_AZURE_ENTRA_PASSWORD_CREDENTIALS_ENABLED" )
Variables ¶
This section is empty.
Functions ¶
func NormalizeAzureCloud ¶
func WriteToEnvStr ¶
func WriteToEnvStr(azureSettings *AzureSettings) []string
Types ¶
type AzureCloudInfo ¶
type AzureCloudSettings ¶
type AzureSettings ¶
type AzureSettings struct { AzureAuthEnabled bool Cloud string ManagedIdentityEnabled bool ManagedIdentityClientId string WorkloadIdentityEnabled bool WorkloadIdentitySettings *WorkloadIdentitySettings UserIdentityEnabled bool UserIdentityTokenEndpoint *TokenEndpointSettings UserIdentityFallbackCredentialsEnabled bool // This field determines which plugins will receive the settings via plugin context ForwardSettingsPlugins []string CustomCloudList []*AzureCloudSettings CustomCloudListJSON string AzureEntraPasswordCredentialsEnabled bool }
func ReadFromContext ¶
func ReadFromContext(ctx context.Context) (*AzureSettings, bool)
Changes here are dependant on https://github.com/grafana/grafana/tree/main/pkg/plugins/envvars/envvars.go#L148
func ReadFromEnv ¶
func ReadFromEnv() (*AzureSettings, error)
func ReadSettings ¶
func ReadSettings(ctx context.Context) (*AzureSettings, error)
func (*AzureSettings) Clouds ¶
func (settings *AzureSettings) Clouds() []AzureCloudInfo
Returns all clouds configured on the instance, including custom clouds if any
func (*AzureSettings) CustomClouds ¶ added in v2.0.2
func (settings *AzureSettings) CustomClouds() []AzureCloudInfo
Returns only the custom clouds configured on the instance
func (*AzureSettings) GetCloud ¶
func (settings *AzureSettings) GetCloud(cloudName string) (*AzureCloudSettings, error)
func (*AzureSettings) GetDefaultCloud ¶
func (settings *AzureSettings) GetDefaultCloud() string
func (*AzureSettings) SetCustomClouds ¶ added in v2.0.4
func (settings *AzureSettings) SetCustomClouds(customCloudsJSON string) error
Parses the JSON list of custom clouds passed in, then stores the list on the instance
type TokenEndpointSettings ¶
Click to show internal directories.
Click to hide internal directories.