forked from AcademySoftwareFoundation/rez
-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (54 loc) · 1.92 KB
/
windows.yaml
1
2
3
4
5
6
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#
# Picks up docker image from hub.docker.com as repository.
#
# Pulls without login (public repository only).
# Requires username/repository to match the github repository.
# For example: nerdvegas/rez -> User/Repository: nerdvegas
#
# Uses image tagged as **latest** commit revision of any file within:
# .github/docker/windows/**
# .github/workflows/windows-docker-image.yaml
#
name: windows
on:
pull_request:
paths-ignore:
- '.github/docker/**'
- '.github/workflows/windows-docker-image.yaml'
- 'src/rez/utils/_version.py'
- 'wiki/**'
- 'metrics/**'
- '**.md'
push:
paths-ignore:
- '.github/docker/**'
- '.github/workflows/windows-docker-image.yaml'
- 'src/rez/utils/_version.py'
- 'wiki/**'
- 'metrics/**'
- '**.md'
jobs:
main:
runs-on: windows-2019
env:
# DockerHub base image name. May switch to GitHub Docker Packages
# in the future. See GitHub Issue #789 and PR #830
BASE_IMAGE_NAME: "nerdvegas/rez-win-py:${{ matrix.python-version }}"
strategy:
matrix:
# Needs to match python version of images (see windows-docker-image.yaml)
python-version:
- '2.7.17'
# TODO add back once failing windows py3 builds are investigated
#- '3.6.8'
#- '3.7.5'
fail-fast: false
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Run Docker image (installs and tests rez)
run: |
${Env:LAST_DOCKER_REVISION} = $( git log -n 1 --author-date-order --pretty=format:%H -- .\.github\docker\rez-win-py\ .\.github\docker\rez-win-base\ .\.github\workflows\windows-docker-image.yaml ).SubString(0, 8)
${docker_image} = "${{ Env.BASE_IMAGE_NAME }}-${Env:LAST_DOCKER_REVISION}"
Write-Output "Running DockerHub ${docker_image}..."
docker run --mount type=bind,src=$pwd,dst=C:\checkout,readonly ${docker_image}