Azure SQL Database Plugin
The plugin provides functionality to interact with Azure SQL Database.
Installation
implementation(group: 'org.vividus', name: 'vividus-plugin-azure-sql-db', version: '0.4.16')
SQL Database management
Configuration
Authentication
The authentication process relies on the configuration of the environment variables.
See the official "Azure identity" guide to get more details on what types of authentication could be used.
Azure environment selection
Azure environment
could be optionally specified using either global property azure.environment
(sets the environment for all Azure plugins) or plugin-specific property
azure.sql-db.environment
. The plugin-specific property takes
precedence over the global one. The default value is AZURE
.
The plugin-specific property azure.sql-db.environment is deprecated and will be removed in VIVIDUS 0.5.0. The global property must be used.
|
The supported environments are only:
-
AZURE
-
AZURE_CHINA
-
AZURE_GERMANY
-
AZURE_US_GOVERNMENT
Steps
Collect SQL Servers info
Collects the info about all the SQL Servers under the specified resource group and saves it as JSON to a variable. For more information, see the Azure Docs.
When I collect SQL Servers from resource group `$resourceGroupName` and save them as JSON to $scopes variable `$variableName`
-
$resourceGroupName
- The name of the resource group within the user’s subscription to retrieve SQL Servers from. The name is case-insensitive. -
$variableName
- The variable name to store the info about SQL Servers as JSON.
When I collect SQL Servers from resource group `TEST-SQL` and save them as JSON to scenario variable `sql-servers`
Collect SQL Databases info
Collects the info about all the databases belonging to the identified SQL Server under the specified resource group and saves it as JSON to a variable. For more information, see the Azure Docs.
When I collect databases from SQL Server `$sqlServerName` from resource group `$resourceGroupName` and save them as JSON to $scopes variable `$variableName`
-
$sqlServerName
- The name of the SQL Server to list databases from. -
$resourceGroupName
- The name of the resource group within the user’s subscription to retrieve the SQL Server from. The name is case-insensitive. -
$variableName
- The variable name to store the info about databases as JSON.
When I collect databases from SQL Server `geography-server` from resource group `TEST-SQL` and save them as JSON to scenario variable `sql-dbs`
Retrieve the SQL Database properties
Retrieves the properties of the specified SQL Database belonging to the identified SQL Server and saves them as JSON to a variable. For more information, see the Azure Docs.
When I retrieve properties of database with name `$databaseName` from SQL Server `$sqlServerName` from resource group `$resourceGroupName` and save them as JSON to $scopes variable `$variableName`
-
$databaseName
- The name of the SQL Database. -
$sqlServerName
- The name of the SQL Server. -
$resourceGroupName
- The name of the resource group within the user’s subscription to retrieve the SQL Server from. The name is case-insensitive. -
$variableName
- The variable name to store the SQL Database properties as JSON.
When I retrieve properties of database with name `CITY-DB` from SQL Server `geography-server` from resource group `TEST-SQL` and save them as JSON to scenario variable `sql-db-properties`