Skip to content
Prev Previous commit
Next Next commit
Update app_service_environments_create_or_update_multi_role_pool.py
  • Loading branch information
msyyc authored Nov 15, 2024
commit 69aefbf67140292c6e7c72f8ed17565658bb68ea
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from azure.identity import DefaultAzureCredential

from azure.mgmt.web import WebSiteManagementClient

"""
# PREREQUISITES
pip install azure-identity
Expand All @@ -21,21 +22,22 @@
AZURE_CLIENT_SECRET. For more info about how to get the value, please see:
https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal
"""


def main():
client = WebSiteManagementClient(
credential=DefaultAzureCredential(),
subscription_id="34adfa4f-cedf-4dc0-ba29-b6d1a69ab345",
)

response = client.app_service_environments.update_multi_role_pool(
resource_group_name='test-rg',
name='test-ase',
multi_role_pool_envelope={'properties': {'workerCount': 3, 'workerSize': 'Medium'}},
)
response = client.app_service_environments.begin_create_or_update_multi_role_pool(
resource_group_name="test-rg",
name="test-ase",
multi_role_pool_envelope={"properties": {"workerCount": 3, "workerSize": "Medium"}},
).result()
print(response)


# x-ms-original-file: specification/web/resource-manager/Microsoft.Web/stable/2024-04-01/examples/AppServiceEnvironments_CreateOrUpdateMultiRolePool.json
if __name__ == "__main__":
main()
= "__main__":
main()
Loading