Skip to content

Commit

Permalink
Update autoaz_stu.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Seeger0216 authored May 5, 2021
1 parent 2ad2176 commit e93c098
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions autoaz_stu.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,17 +83,18 @@ def get_random_alpha(ab_a=int(65), ab_b=int(90)) -> str:

# 4.批量创建虚拟机并运行挖矿脚本
print("正在 " + str(location1) + " 区域创建 " + str(size1_name)+" 实例")
a = 'Mine'
get_default_cli().invoke(
['vm', 'create', '--resource-group', res_name, '--name',
f'{location1}-{size1_abbreviation}', '--image', 'UbuntuLTS',
f'{a}-{size1_abbreviation}', '--image', 'UbuntuLTS',
'--size', f'{size1_name}', '--location', f'{location1}', '--admin-username',
'azureuser', '--admin-password', '6uPF5Cofvyjcew9', '--custom-data',
'cloud-init.txt', "--no-wait"])
print("正在 " + str(location2) + " 区域创建 " + str(size2_name)+" 实例")
get_default_cli().invoke(
['vm', 'create', '--resource-group', res_name, '--name',
f'{location2}-{size2_abbreviation}', '--image', 'UbuntuLTS',
'--size', f'{size2_name}', '--location', f'{location1}', '--admin-username',
f'{a}-{size2_abbreviation}', '--image', 'UbuntuLTS',
'--size', f'{size2_name}', '--location', f'{location2}', '--admin-username',
'azureuser', '--admin-password', '6uPF5Cofvyjcew9', '--custom-data',
'cloud-init.txt', "--no-wait"])

Expand Down

0 comments on commit e93c098

Please sign in to comment.