{"modulePath":"github.com/Method-Security/methodazure","version":"v0.0.17","isLatest":false,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package database\n\nPackage database provides functions and data structures to interact with Azure Database resources.\n\n## Types\n\n```go\ntype AzureResourceReport struct {\n\tResources AzureResources `json:\"resources\" yaml:\"resources\"`\n\tErrors    []string       `json:\"errors\" yaml:\"errors\"`\n}\n```\nAzureResourceReport contains the AzureResources and any non-fatal errors encountered during enumeration.\n\n```go\nfunc EnumerateDatabaseInstances(ctx context.Context, cfg config.AzureConfig) (*AzureResourceReport, error)\n```\nEnumerateDatabaseInstances enumerates all managed Database instances in the subscription, returning a report of the instances and any non-fatal errors encountered.\n\n```go\ntype AzureResources struct {\n\tSubscriptionID            string                            `json:\"subscription_id\" yaml:\"subscription_id\"`\n\tTenantID                  string                            `json:\"tenant_id\" yaml:\"tenant_id\"`\n\tSQLInstances              []SQLInstanceDetails              `json:\"sql_instances\" yaml:\"sql_instances\"`\n\tPostgresInstances         []PostgresInstanceDetails         `json:\"postgres_instances\" yaml:\"postgres_instances\"`\n\tPostgresFlexibleInstances []PostgresFlexibleInstanceDetails `json:\"postgres_flexible_instances\" yaml:\"postgres_flexible_instances\"`\n}\n```\nAzureResources contains details about all database instances in the subscription.\n\n```go\ntype PostgresFlexibleInstanceDetails struct {\n\tInstanceName    string                              `json:\"instance_name\" yaml:\"instance_name\"`\n\tLocation        string                              `json:\"location\" yaml:\"location\"`\n\tResourceGroup   string                              `json:\"resource_group\" yaml:\"resource_group\"`\n\tResourceGroupID string                              `json:\"resource_group_id\" yaml:\"resource_group_id\"`\n\tVNetID          string                              `json:\"vnet_id\" yaml:\"vnet_id\"`\n\tDetails         armpostgresqlflexibleservers.Server `json:\"details\" yaml:\"details\"`\n}\n```\nPostgresFlexibleInstanceDetails contains details about a single PostgreSQL Flexible instance.\n\n```go\ntype PostgresInstanceDetails struct {\n\tInstanceName    string               `json:\"instance_name\" yaml:\"instance_name\"`\n\tLocation        string               `json:\"location\" yaml:\"location\"`\n\tResourceGroup   string               `json:\"resource_group\" yaml:\"resource_group\"`\n\tResourceGroupID string               `json:\"resource_group_id\" yaml:\"resource_group_id\"`\n\tVNetID          string               `json:\"vnet_id\" yaml:\"vnet_id\"`\n\tDetails         armpostgresql.Server `json:\"details\" yaml:\"details\"`\n}\n```\nPostgresInstanceDetails contains details about a single PostgreSQL instance.\n\n```go\ntype SQLInstanceDetails struct {\n\tInstanceName    string                 `json:\"instance_name\" yaml:\"instance_name\"`\n\tLocation        string                 `json:\"location\" yaml:\"location\"`\n\tResourceGroup   string                 `json:\"resource_group\" yaml:\"resource_group\"`\n\tResourceGroupID string                 `json:\"resource_group_id\" yaml:\"resource_group_id\"`\n\tVNetID          string                 `json:\"vnet_id\" yaml:\"vnet_id\"`\n\tDetails         armsql.ManagedInstance `json:\"details\" yaml:\"details\"`\n}\n```\nSQLInstanceDetails contains details about a single SQL instance.\n\n","path":"github.com/Method-Security/methodazure/internal/database","name":"database","synopsis":"Package database provides functions and data structures to interact with Azure Database resources.","isRedistributable":true}
