Skip to content

Commit 47576f2

Browse files
committed
docker: add action to deploy windows build image
1 parent 6105af8 commit 47576f2

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Docker (Windows)
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- .github/workflows/build_windows.yml
7+
- ansible/docker/Dockerfile.win2022
8+
branches:
9+
- master
10+
push:
11+
paths:
12+
- .github/workflows/build_windows.yml
13+
- ansible/docker/Dockerfile.win2022
14+
branches:
15+
- master
16+
17+
permissions:
18+
id-token: write
19+
contents: read
20+
21+
jobs:
22+
build:
23+
if: startsWith(github.repository, 'adoptium/')
24+
runs-on: windows-latest
25+
steps:
26+
- name: Login to our Azure subscription
27+
if: github.ref == 'refs/heads/master'
28+
uses: azure/login@a65d910e8af852a8061c627c456678983e180302 # v2.2.0
29+
with:
30+
client-id: ${{ secrets.AZURE_CLIENT_ID_OIDC }}
31+
tenant-id: ${{ secrets.AZURE_TENANT_ID }}
32+
subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }}
33+
34+
- name: Login to Azure Container Registry
35+
if: github.ref == 'refs/heads/master'
36+
run: az acr login --name adoptium
37+
38+
- name: Build container image and push to Azure
39+
uses: docker/build-push-action@4f58ea79222b3b9dc2c8bbdd6debcef730109a75 # v6.9.0
40+
with:
41+
file: ansible/docker/Dockerfile.win2022
42+
tags: adoptium.azurecr.io/windows2022_build_image:latest
43+
push: github.ref == 'refs/heads/master'

0 commit comments

Comments
 (0)