Create management groups and subscriptions
Note
|
Before Using
|
This script offers the following commands:
-
create-subscription
creates a new subscription. -
create-management-group
creates a new management group. -
associate-management-group
associates and existing subscription with a management group.
python subscription.py create-subscription {arguments}
python3 subscription.py create-subscription {arguments}
py subscription.py create-subscription {arguments}
Argument | Required? | Description |
---|---|---|
|
Required |
The name of the subscription to create. |
|
Required |
Azure’s subscription offer type (i.e. MS-AZR-0017P). |
|
Optional |
If not passed, the code will look for a default billing enrollment account name (first value found). |
python subscription.py create-management-group {arguments}
python3 subscription.py create-management-group {arguments}
py subscription.py create-management-group {arguments}
Argument | Required? | Description |
---|---|---|
|
Required |
The id of the management group to be created. |
|
Optional |
If specified, the subscription gets associated to the new management group. |
|
Optional |
If specified, the script will try to identify the subscription id by its name) and then associated it to the management group created. Passing |
python subscription.py associate-management-group {arguments}
python3 subscription.py associate-management-group {arguments}
py subscription.py associate-management-group {arguments}