зеркало из https://github.com/Azure/azurehpc.git
KV test and triggers
This commit is contained in:
Родитель
27fe19627c
Коммит
76e6a02d8a
|
@ -73,6 +73,10 @@ if [[ "$return_code" -ne "0" ]] || [[ "$show_logs" == "true" ]]; then
|
|||
config_file_no_path_or_extension=${config_file_no_path%.*}
|
||||
tmp_dir=azhpc_install_$config_file_no_path_or_extension
|
||||
if [ -d $tmp_dir ]; then
|
||||
echo "============"
|
||||
echo "Dumping logs"
|
||||
echo "============"
|
||||
echo ""
|
||||
cat $tmp_dir/install/*.log
|
||||
set +e
|
||||
grep -A4 "\[FAILURE\]" $tmp_dir/install/*.log
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
parameters:
|
||||
pre_steps: ''
|
||||
extra_steps: ''
|
||||
|
||||
jobs:
|
||||
|
@ -27,8 +28,11 @@ jobs:
|
|||
echo "##vso[task.setvariable variable=azhpc.ResourceGroup]$ResourceGroup"
|
||||
mkdir -p $(Pipeline.Workspace)/$(System.JobName)
|
||||
echo "$ResourceGroup" > $(Pipeline.Workspace)/$(System.JobName)/azhpc.ResourceGroup
|
||||
|
||||
- task: AzureCLI@2
|
||||
|
||||
- ${{ if not(eq(parameters.pre_steps,'')) }}:
|
||||
- template: ${{parameters.pre_steps}}
|
||||
|
||||
- task: AzureCLI@2
|
||||
displayName: "Build Resources"
|
||||
inputs:
|
||||
azureSubscription: 'target-subscription'
|
||||
|
|
|
@ -10,7 +10,8 @@
|
|||
"bool_value": true,
|
||||
"simple_variable": "value",
|
||||
"use_variable": "variables.simple_variable",
|
||||
"double_curly_braces": "simple_variable={{variables.simple_variable}}"
|
||||
"double_curly_braces": "simple_variable={{variables.simple_variable}}",
|
||||
"key_vault": "variables.resource_group"
|
||||
},
|
||||
"vnet": {
|
||||
"name": "hpcvnet",
|
||||
|
@ -27,7 +28,8 @@
|
|||
"variables.bool_value", true,
|
||||
"variables.simple_variable", "value",
|
||||
"variables.use_variable", "value",
|
||||
"variables.double_curly_braces", "simple_variable=value"
|
||||
"variables.double_curly_braces", "simple_variable=value",
|
||||
"secret.{{variables.key_vault}}.secret", "secretvalue"
|
||||
]
|
||||
}
|
||||
]
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
pr: none
|
||||
trigger: none
|
||||
# batch: true
|
||||
# branches:
|
||||
# include:
|
||||
# - '*'
|
||||
# paths:
|
||||
# include:
|
||||
# - examples/nvidia/*
|
||||
# - scripts/update_kernel.sh
|
||||
# exclude:
|
||||
# - examples/nvidia/readme.md
|
||||
trigger:
|
||||
batch: true
|
||||
branches:
|
||||
include:
|
||||
- '*'
|
||||
paths:
|
||||
include:
|
||||
- pyazhpc/azconfig.py
|
||||
- pyazhpc/azutil.py
|
||||
- pyazhpc/test/azconfig/*
|
||||
- pyazhpc/test/azconfig/scripts/*
|
||||
|
||||
pool: Default
|
||||
|
||||
|
@ -32,5 +32,5 @@ variables:
|
|||
|
||||
jobs:
|
||||
- template: ../../../ci/templates/jobs/build.yml
|
||||
# parameters:
|
||||
# extra_steps: ../../../examples/nvidia/test.yml
|
||||
parameters:
|
||||
pre_steps: ../../../../pyazhpc/test/azconfig/pre_steps.yml
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
steps:
|
||||
- task : AzureCLI@2
|
||||
displayName: "Create unit test resources"
|
||||
inputs:
|
||||
azureSubscription: 'target-subscription'
|
||||
scriptType: 'bash'
|
||||
scriptLocation: inlineScript
|
||||
inlineScript: |
|
||||
if [ "$SYSTEM_DEBUG" = "true" ]; then
|
||||
set -x
|
||||
fi
|
||||
|
||||
# extract the random value from the resource group
|
||||
random=$(echo $AZHPC_RESOURCEGROUP | cut -d '-' -f2)
|
||||
|
||||
# Create a KeyVault and add a secret in it
|
||||
az keyvault create --name $AZHPC_RESOURCEGROUP --resource-group $AZHPC_RESOURCEGROUP --output table
|
||||
az keyvault secret set --vault-name $AZHPC_RESOURCEGROUP --name "secret" --value "secretvalue" --output table
|
||||
|
||||
failOnStandardError: false
|
||||
continueOnError: false
|
||||
|
Загрузка…
Ссылка в новой задаче