From d04aaa8f1293a92a1608164fb944eb9baadbdf52 Mon Sep 17 00:00:00 2001 From: MyronFanQiu Date: Sun, 19 Jan 2020 17:58:56 +0800 Subject: [PATCH 1/2] add warning --- src/azure-cli/azure/cli/command_modules/network/custom.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/azure-cli/azure/cli/command_modules/network/custom.py b/src/azure-cli/azure/cli/command_modules/network/custom.py index 3c783931520..17616d7a413 100644 --- a/src/azure-cli/azure/cli/command_modules/network/custom.py +++ b/src/azure-cli/azure/cli/command_modules/network/custom.py @@ -1945,6 +1945,8 @@ def _add_save_record(cmd, record, record_type, record_set_name, resource_group_n try: record_set = ncf.get(resource_group_name, zone_name, record_set_name, record_type) except CloudError: + logger.warning("The record set doesn't exist and is automatically created. " + "In the future, an extra argument will be supported to confirm this auto creation.") RecordSet = cmd.get_models('RecordSet', resource_type=ResourceType.MGMT_NETWORK_DNS) record_set = RecordSet() From 9a6e93a77c5151ea56f452060ca0b1e20fdd790b Mon Sep 17 00:00:00 2001 From: MyronFanQiu Date: Mon, 20 Jan 2020 10:03:36 +0800 Subject: [PATCH 2/2] update history --- src/azure-cli/HISTORY.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/azure-cli/HISTORY.rst b/src/azure-cli/HISTORY.rst index caf62efa72a..3c29d46fb25 100644 --- a/src/azure-cli/HISTORY.rst +++ b/src/azure-cli/HISTORY.rst @@ -24,6 +24,10 @@ Release History * Fix #6371: Support filename and environment variable completion in Bash +**Network** + +* Fix #2092: az network dns record-set add/remove: add warning when record-set is not found. In the future, an extra argument will be supported to confirm this auto creation. + **Storage** * Add a new command group `az storage share-rm` to use the Microsoft.Storage resource provider for Azure file share management operations.