az postgres flexible-server advanced-threat-protection-setting

Manage advanced threat protection setting for a PostgreSQL flexible server.

Commands

Name Description Type Status
az postgres flexible-server advanced-threat-protection-setting show

Get advanced threat protection settings for a PostgreSL flexible server.

Core GA
az postgres flexible-server advanced-threat-protection-setting update

Updates advanced threat protection setting state for a flexible server.

Core GA

az postgres flexible-server advanced-threat-protection-setting show

Get advanced threat protection settings for a PostgreSL flexible server.

az postgres flexible-server advanced-threat-protection-setting show [--ids]
                                                                    [--resource-group]
                                                                    [--server-name]
                                                                    [--subscription]

Examples

Get the details of advanced threat protection setting for a flexible server.

az postgres flexible-server advanced-threat-protection-setting show --resource-group testGroup --server-name testserver

Get the details of advanced threat protection setting for a flexible server in a different subscription.

az postgres flexible-server advanced-threat-protection-setting show --subscription testSubscription --resource-group testGroup --server-name testserver

Get the details of advanced threat protection setting for a flexible server using --ids parameter.

az postgres flexible-server advanced-threat-protection-setting show --ids /subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/testGroup/providers/Microsoft.DBforPostgreSQL/flexibleServers/testServer

Optional Parameters

--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--server-name -s

Name of the server. The name can contain only lowercase letters, numbers, and the hyphen (-) character. Minimum 3 characters and maximum 63 characters.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

accepted values: json, jsonc, none, table, tsv, yaml, yamlc
default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.

az postgres flexible-server advanced-threat-protection-setting update

Updates advanced threat protection setting state for a flexible server.

az postgres flexible-server advanced-threat-protection-setting update --state {Disabled, Enabled}
                                                                      [--ids]
                                                                      [--resource-group]
                                                                      [--server-name]
                                                                      [--subscription]

Examples

Enable advanced threat protection setting for a PostgreSQL flexible server.

az postgres flexible-server advanced-threat-protection-setting update --resource-group testGroup --server-name testserver --state Enabled

Disable advanced threat protection setting for a PostgreSQL flexible server.

az postgres flexible-server advanced-threat-protection-setting update --resource-group testGroup --server-name testserver --state Disabled

Required Parameters

--state

State of advanced threat protection setting.

accepted values: Disabled, Enabled

Optional Parameters

--ids

One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

--server-name -s

Name of the server. The name can contain only lowercase letters, numbers, and the hyphen (-) character. Minimum 3 characters and maximum 63 characters.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

Global Parameters
--debug

Increase logging verbosity to show all debug logs.

--help -h

Show this help message and exit.

--only-show-errors

Only show errors, suppressing warnings.

--output -o

Output format.

accepted values: json, jsonc, none, table, tsv, yaml, yamlc
default value: json
--query

JMESPath query string. See http://jmespath.org/ for more information and examples.

--subscription

Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID.

--verbose

Increase logging verbosity. Use --debug for full debug logs.