ansible-integration-test.yml 886 Bytes
Newer Older
1
2
3
4
5
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.

trigger:
  - main
6
  - release/*
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34

pool:
  name: SuperBench CI
  vmImage: ubuntu-latest

container:
  image: nvcr.io/nvidia/pytorch:20.12-py3

steps:
  - task: DownloadSecureFile@1
    name: vagrantKeyFile
    displayName: Download key file
    inputs:
      secureFile: vagrant.key
  - script: |
      echo "##vso[task.prependpath]$HOME/.local/bin"
    displayName: Export path
  - script: |
      python3 -m pip install .[test]
      make postinstall
    displayName: Install Ansible dependencies
  - script: |
      chmod 400 $(vagrantKeyFile.secureFilePath)
      sed -i "s\vagrant.key\$(vagrantKeyFile.secureFilePath)\g" tests/ansible/hosts.ini
      export ANSIBLE_HOST_KEY_CHECKING=False
      bash tests/ansible/test.sh
    displayName: Run integration tests for Ansible playbooks
    timeoutInMinutes: 10