Skip to content

Commit

Permalink
Login node option in marketplace application (#1850)
Browse files Browse the repository at this point in the history
* vmsize and number of nodes are required for partitions

* remove extra)

* ssh port is 22 when using bastion

* fix wrong bastion ports

* use Standard_D4as_v4 for ccportal and scheduler

* toolset on alma

* fix syntax

* fix alma test

* fix installation script on CentOS

* ccportal as deployer

* install in /opt and not root

* adding login node in marketplace template
  • Loading branch information
xpillons authored Feb 21, 2024
1 parent 8a57d4c commit ea32159
Show file tree
Hide file tree
Showing 3 changed files with 121 additions and 8 deletions.
18 changes: 18 additions & 0 deletions bicep/mainTemplate.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,23 @@ param databaseAdminPassword string = ''
@description('Input configuration file in json format')
param azhopConfig object

@description('CycleCloud VM Size')
param ccVMSize string = ''
@description('Scheduler VM Size')
param schedulerVMSize string = ''
@description('loginNode VM Size')
param loginVMSize string = ''
@description('htcVMSize VM Size')
param htcVMSize string = ''
@description('hpcVMSize VM Size')
param hpcVMSize string = ''
@description('gpuVMSize VM Size')
param gpuVMSize string = ''

var resource_group_name = azhopConfig.resource_group
// This is to pass the arm-ttk test "VMSizes Must Match Template" and "Outputs Must Be Present In Template Parameters" and "Parameters Must Be Used"
// These values are already filled in the config file, so we are just passing them through
var fakeOutput = '${ccVMSize}/${schedulerVMSize}/${loginVMSize}/${htcVMSize}/${hpcVMSize}/${gpuVMSize}'

resource azhopResourceGroup 'Microsoft.Resources/resourceGroups@2022-09-01' = {
name: resource_group_name
Expand Down Expand Up @@ -78,3 +94,5 @@ resource roleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = {
principalType: 'ServicePrincipal'
}
}

output fakeOutput string = fakeOutput
11 changes: 10 additions & 1 deletion marketplace/solution/cc-slurm-workspace/marketplace_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,16 +147,25 @@ queues:
max_count: "[steps('Partitions').HTCSection.NodeNumber]"
image: "[steps('Partitions').HTCSection.ImageName]"
ColocateNodes: false
type: compute
- name: hpc
vm_size: "[steps('Partitions').HPCSection.vmsize]"
max_count: "[steps('Partitions').HPCSection.NodeNumber]"
image: "[steps('Partitions').HPCSection.ImageName]"
EnableAcceleratedNetworking: true
ColocateNodes: true
type: compute
- name: gpu
vm_size: "[steps('Partitions').GPUSection.vmsize]"
max_count: "[steps('Partitions').GPUSection.NodeNumber]"
image: "[steps('Partitions').GPUSection.ImageName]"
EnableAcceleratedNetworking: true
ColocateNodes: true

type: compute
- name: login
vm_size: "[steps('login').vmsize]"
max_count: "[steps('login').NodeNumber]"
image: "[steps('login').ImageName]"
initial_count: "[steps('login').InitialCount]"
ColocateNodes: false
type: login
100 changes: 93 additions & 7 deletions marketplace/solution/cc-slurm-workspace/ui_definition.json
Original file line number Diff line number Diff line change
Expand Up @@ -452,6 +452,86 @@
}
]
},
{
"name": "login",
"label": "Login Node",
"subLabel": {
"preValidation": "Configure your Login node settings",
"postValidation": "Done"
},
"bladeTitle": "Login Node Settings",
"elements": [
{
"name": "vmsize",
"type": "Microsoft.Compute.SizeSelector",
"label": "Size",
"toolTip": "Select a VM Size for the Login nodes",
"recommendedSizes": [
"Standard_F4s_v2"
],
"options": {
"hideDiskTypeFilter": true
},
"osPlatform": "Linux",
"visible": true,
"required": true,
"validationMessage": "VMSize is required."
},
{
"name": "InitialCount",
"type": "Microsoft.Common.Slider",
"label": "Number of nodes to start with",
"toolTip": "Number of nodes to start with when the cluster starts",
"subLabel": "Initial Count",
"defaultValue": 1,
"min": 0,
"max": 8,
"step": 1,
"visible": true,
"required": true,
"validationMessage": "Initial Number of nodes is required"
},
{
"name": "NodeNumber",
"type": "Microsoft.Common.Slider",
"label": "Max number of nodes",
"toolTip": "Maximum number of nodes to scale to",
"subLabel": "Number",
"defaultValue": 1,
"min": 0,
"max": 8,
"step": 1,
"visible": true,
"required": true,
"validationMessage": "Number of nodes is required"
},
{
"name": "ImageName",
"type": "Microsoft.Common.DropDown",
"label": "Image Name",
"defaultValue": "Alma Linux 8.7",
"toolTip": "Select the image to use for the Login nodes",
"constraints": {
"allowedValues": [
{
"label": "Ubuntu 20.04",
"value": "microsoft-dsvm:ubuntu-hpc:2004:latest"
},
{
"label": "Ubuntu 22.04",
"value": "microsoft-dsvm:ubuntu-hpc:2204:latest"
},
{
"label": "Alma Linux 8.7",
"value": "almalinux:almalinux-hpc:8_7-hpc-gen2:latest"
}
],
"required": true,
"validationMessage": "Image Name is required."
}
}
]
},
{
"name": "Partitions",
"label": "Partitions",
Expand Down Expand Up @@ -481,11 +561,11 @@
"visible": true,
"required": true,
"validationMessage": "VMSize is required."
},
},
{
"name": "NodeNumber",
"type": "Microsoft.Common.Slider",
"label": "Number of nodes",
"label": "Max number of nodes",
"toolTip": "Maximum number of nodes to scale to",
"subLabel": "Number",
"defaultValue": 32,
Expand All @@ -494,7 +574,7 @@
"step": 4,
"visible": true,
"required": true,
"validationMessage": "Number of nodes is required"
"validationMessage": "Max number of nodes is required"
},
{
"name": "ImageName",
Expand Down Expand Up @@ -547,7 +627,7 @@
{
"name": "NodeNumber",
"type": "Microsoft.Common.Slider",
"label": "Number of nodes",
"label": "Max number of nodes",
"toolTip": "Maximum number of nodes to scale to",
"subLabel": "Number",
"defaultValue": 4,
Expand All @@ -556,7 +636,7 @@
"step": 2,
"visible": true,
"required": true,
"validationMessage": "Number of nodes is required"
"validationMessage": "Max number of nodes is required"
},
{
"name": "ImageName",
Expand Down Expand Up @@ -611,7 +691,7 @@
{
"name": "NodeNumber",
"type": "Microsoft.Common.Slider",
"label": "Number of nodes",
"label": "Max number of nodes",
"toolTip": "Maximum number of nodes to scale to",
"subLabel": "Number",
"defaultValue": 4,
Expand All @@ -620,7 +700,7 @@
"step": 2,
"visible": true,
"required": true,
"validationMessage": "Number of nodes is required"
"validationMessage": "Max number of nodes is required"
},
{
"name": "ImageName",
Expand Down Expand Up @@ -697,6 +777,12 @@
"adminSshPrivateKey": "[if(basics('autogeneratePasswordsAndKeys'),'',basics('adminSshPrivateKey'))]",
"adminPassword": "[if(basics('autogeneratePasswordsAndKeys'),'',basics('adminPassword'))]",
"databaseAdminPassword": "[if(and(basics('autogeneratePasswordsAndKeys'), steps('scheduler').slurmAccounting)),'',steps('scheduler').databaseAdminPassword)]",
"ccVMSize": "[basics('CycleCloudVmSize')]",
"schedulerVMSize": "[steps('scheduler').vmsize]",
"loginVMSize": "[steps('login').vmsize]",
"htcVMSize": "[steps('Partitions').HTCSection.vmsize]",
"hpcVMSize": "[steps('Partitions').HPCSection.vmsize]",
"gpuVMSize": "[steps('Partitions').GPUSection.vmsize]",
"azhopConfig": {}
}
}
Expand Down

0 comments on commit ea32159

Please sign in to comment.