Skip to content

Commit 400d625

Browse files
Release 2.10.0
1 parent fd16b91 commit 400d625

File tree

4 files changed

+212
-133
lines changed

4 files changed

+212
-133
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ extensions:
2020

2121
To run this sample:
2222

23-
See [DefaultAzureCredential](https://github.com/Azure/azure-sdk-for-java/tree/master/sdk/identity/azure-identity#defaultazurecredential) and prepare the authentication works best for you. For more details on authentication, please refer to [AUTH.md](https://github.com/Azure/azure-sdk-for-java/blob/master/sdk/resourcemanager/docs/AUTH.md).
23+
See [DefaultAzureCredential](https://github.com/Azure/azure-sdk-for-java/tree/main/sdk/identity/azure-identity#defaultazurecredential) and prepare the authentication works best for you. For more details on authentication, please refer to [AUTH.md](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/resourcemanager/docs/AUTH.md).
2424

2525
git clone https://github.com/Azure-Samples/compute-java-manage-virtual-machines-in-parallel.git
2626

pom.xml

+7-2
Original file line numberDiff line numberDiff line change
@@ -54,12 +54,17 @@
5454
<dependency>
5555
<groupId>com.azure.resourcemanager</groupId>
5656
<artifactId>azure-resourcemanager</artifactId>
57-
<version>2.1.0</version>
57+
<version>2.10.0</version>
5858
</dependency>
5959
<dependency>
6060
<groupId>com.azure</groupId>
6161
<artifactId>azure-identity</artifactId>
62-
<version>1.2.0</version>
62+
<version>1.4.1</version>
63+
</dependency>
64+
<dependency>
65+
<groupId>com.jcraft</groupId>
66+
<artifactId>jsch</artifactId>
67+
<version>0.1.55</version>
6368
</dependency>
6469
<dependency>
6570
<groupId>commons-net</groupId>

src/main/java/com/azure/resourcemanager/compute/samples/ManageVirtualMachinesInParallel.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public static boolean runSample(AzureResourceManager azureResourceManager) {
4242
final String networkName = Utils.randomResourceName(azureResourceManager, "vnetCOMV", 24);
4343
final String storageAccountName = Utils.randomResourceName(azureResourceManager, "stgCOMV", 20);
4444
final String userName = "tirekicker";
45-
final String password = Utils.password();
45+
final String sshPublicKey = Utils.sshPublicKey();
4646
try {
4747
// Create a resource group [Where all resources gets created]
4848
ResourceGroup resourceGroup = azureResourceManager.resourceGroups()
@@ -73,7 +73,7 @@ public static boolean runSample(AzureResourceManager azureResourceManager) {
7373
.withoutPrimaryPublicIPAddress()
7474
.withPopularLinuxImage(KnownLinuxVirtualMachineImage.UBUNTU_SERVER_16_04_LTS)
7575
.withRootUsername(userName)
76-
.withRootPassword(password)
76+
.withSsh(sshPublicKey)
7777
.withSize(VirtualMachineSizeTypes.fromString("Standard_D2a_v4"))
7878
.withNewStorageAccount(creatableStorageAccount);
7979
creatableVirtualMachines.add(creatableVirtualMachine);

0 commit comments

Comments
 (0)