-
Notifications
You must be signed in to change notification settings - Fork 1
51 lines (48 loc) · 1.75 KB
/
docker-image.yml
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
name: Docker Image CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
workflow_dispatch:
schedule:
- cron: "0 1 * * 0"
jobs:
ltsc2022:
strategy:
matrix:
VS_VER: ["2022", "2019", "2017"]
runs-on: windows-2022
env:
WIN_VER: ltsc2022
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: build
run: docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/visualstudio${{ matrix.VS_VER }}-workload-vctools -t ${{ secrets.DOCKERHUB_USERNAME }}/visualstudio${{ matrix.VS_VER }}-workload-vctools:${{ env.WIN_VER }} --build-arg WIN_VER=${{ env.WIN_VER }} --build-arg VS_VER=${{ matrix.VS_VER }} .
- name: push
run: docker push ${{ secrets.DOCKERHUB_USERNAME }}/visualstudio${{ matrix.VS_VER }}-workload-vctools --all-tags
ltsc2019:
strategy:
matrix:
VS_VER: ["2022", "2019", "2017"]
runs-on: windows-2019
env:
WIN_VER: ltsc2019
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: build
run: docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/visualstudio${{ matrix.VS_VER }}-workload-vctools:${{ env.WIN_VER }} --build-arg WIN_VER=${{ env.WIN_VER }} --build-arg VS_VER=${{ matrix.VS_VER }} .
- name: push
run: docker push ${{ secrets.DOCKERHUB_USERNAME }}/visualstudio${{ matrix.VS_VER }}-workload-vctools --all-tags