Skip to content

Commit 8aebd59

Browse files
committed
Revert "chore: try add actions/cache for windows container"
This reverts commit a975628.
1 parent a975628 commit 8aebd59

1 file changed

Lines changed: 22 additions & 11 deletions

File tree

.github/workflows/release_docker_win.yml

Lines changed: 22 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -98,14 +98,25 @@ jobs:
9898
Write-Host "Tags: $tagsString"
9999
100100
- name: Build and push Windows container
101-
uses: docker/build-push-action@v6
102-
with:
103-
context: .
104-
file: Dockerfile.windows
105-
build-args: |
106-
WINDOWS_VERSION=${{ steps.tag.outputs.windows_version }}
107-
WINDOWS_TYPE=${{ matrix.container_type }}
108-
push: ${{ env.IMAGE_PUSH }}
109-
tags: ${{ steps.meta.outputs.tags }}
110-
cache-from: type=gha
111-
cache-to: type=gha,mode=max
101+
shell: pwsh
102+
run: |
103+
$tags = "${{ steps.meta.outputs.tags }}".Split(",")
104+
$tagArgs = @()
105+
foreach ($tag in $tags) {
106+
$tagArgs += "-t"
107+
$tagArgs += $tag.Trim()
108+
}
109+
110+
docker build `
111+
--build-arg WINDOWS_VERSION=${{ steps.tag.outputs.windows_version }} `
112+
--build-arg WINDOWS_TYPE=${{ matrix.container_type }} `
113+
-f Dockerfile.windows `
114+
$tagArgs `
115+
.
116+
117+
if ("${{ env.IMAGE_PUSH }}" -eq "true") {
118+
foreach ($tag in $tags) {
119+
Write-Host "Pushing $($tag.Trim())"
120+
docker push $tag.Trim()
121+
}
122+
}

0 commit comments

Comments
 (0)