Skip to content

Commit

Permalink
[Network] Fix traffic-manager update command. (Azure#4777)
Browse files Browse the repository at this point in the history
* Fix traffic-manager update command.

* Code review feedback.
  • Loading branch information
tjprescott authored Oct 27, 2017
1 parent 0d16ad7 commit 457c606
Show file tree
Hide file tree
Showing 5 changed files with 163 additions and 87 deletions.
3 changes: 0 additions & 3 deletions azure-cli.pyproj
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@
<Compile Include="azure-cli-core\azure\cli\core\tests\test_add_resourcegroup_transform.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_api_profiles.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_application.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_arm.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_cloud.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_command_registration.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_command_with_configured_defaults.py" />
Expand All @@ -75,7 +74,6 @@
<Compile Include="azure-cli-core\azure\cli\core\tests\test_parser.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_profile.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_progress.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_resource_id.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_storage_validators.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_telemetry.py" />
<Compile Include="azure-cli-core\azure\cli\core\tests\test_util.py" />
Expand All @@ -86,7 +84,6 @@
<Compile Include="azure-cli-core\azure\cli\core\_environment.py" />
<Compile Include="azure-cli-core\azure\cli\core\_help.py" />
<Compile Include="azure-cli-core\azure\cli\core\_output.py" />
<Compile Include="azure-cli-core\azure\cli\core\_pkg_util.py" />
<Compile Include="azure-cli-core\azure\cli\core\_profile.py" />
<Compile Include="azure-cli-core\azure\cli\core\_session.py" />
<Compile Include="azure-cli-core\azure\cli\core\telemetry.py" />
Expand Down
2 changes: 1 addition & 1 deletion src/command_modules/azure-cli-network/HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Release History
2.0.18
++++++
* `dns`: Add support for CAA records.

* `traffic-manager profile update`: Fix issue where profiles with endpoints could not be updated.

2.0.17
++++++
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2584,6 +2584,12 @@ def update_traffic_manager_profile(instance, profile_status=None, routing_method
if monitor_path is not None:
instance.monitor_config.path = monitor_path

# TODO: Remove workaround after https://github.com/Azure/azure-rest-api-specs/issues/1940 fixed
for endpoint in instance.endpoints:
endpoint._validation = {
'name': {'readonly': False},
'type': {'readonly': False},
}
return instance


Expand Down
Loading

0 comments on commit 457c606

Please sign in to comment.