File tree Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Expand file tree Collapse file tree 2 files changed +18
-2
lines changed Original file line number Diff line number Diff line change @@ -401,13 +401,26 @@ jobs:
401
401
with :
402
402
ref : ${{ inputs.ref }}
403
403
404
+ # - name: Set up Docker Buildx
405
+ # uses: docker/setup-buildx-action@v3
406
+
404
407
- name : Log in to the Container registry
405
408
uses : docker/login-action@v3
406
409
with :
407
410
registry : ${{ inputs.registry }}
408
411
username : ${{ inputs.username }}
409
412
password : ${{ secrets.token }}
410
413
414
+ - name : Pull the last release image to speed up the build with a cache
415
+ continue-on-error : true
416
+ run : |
417
+ VERSION=$(gh release list --json tagName,isLatest --jq '.[] | select(.isLatest)|.tagName | sub("^v"; "")')
418
+ echo VERSION="$VERSION"
419
+ docker pull ${{ inputs.registry }}/${{ inputs.image }}:windows-${{ matrix.windows-base-version }}-$VERSION
420
+ shell : bash
421
+ env :
422
+ GH_TOKEN : ${{ secrets.token }}
423
+
411
424
- name : Build the production images
412
425
run : |
413
426
docker build -t ${{ inputs.registry }}/${{ inputs.image }}:windows-${{ matrix.windows-base-version }}-${{ inputs.version }} --build-arg FLB_NIGHTLY_BUILD=${{ inputs.unstable }} --build-arg WINDOWS_VERSION=ltsc${{ matrix.windows-base-version }} -f ./dockerfiles/Dockerfile.windows .
Original file line number Diff line number Diff line change 14
14
ARG WINDOWS_VERSION=ltsc2019
15
15
16
16
# Builder Image - Windows Server Core
17
- FROM mcr.microsoft.com/windows/servercore:$WINDOWS_VERSION AS builder
17
+ FROM mcr.microsoft.com/windows/servercore:$WINDOWS_VERSION AS builder-base
18
18
19
19
RUN setx /M PATH "%PATH%;C:\BuildTools\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin;C:\WinFlexBison;C:\dev\vcpkg"
20
20
@@ -69,6 +69,8 @@ ENV VCPKG_LIBRARY_LINKAGE=static
69
69
RUN vcpkg install --recurse openssl --triplet x64-windows-static; `
70
70
vcpkg install --recurse libyaml --triplet x64-windows-static;
71
71
72
+ FROM builder-base AS builder
73
+
72
74
# Build Fluent Bit from source - context must be the root of the Git repo
73
75
WORKDIR /src/build
74
76
COPY . /src/
@@ -95,7 +97,8 @@ RUN New-Item -Path /fluent-bit/etc/ -ItemType "directory"; `
95
97
Copy-Item -Path /src/conf/parsers_openstack.conf /fluent-bit/etc/; `
96
98
Copy-Item -Path /src/conf/parsers_cinder.conf /fluent-bit/etc/; `
97
99
Copy-Item -Path /src/conf/plugins.conf /fluent-bit/etc/; `
98
- Copy-Item -Path /src/build/bin/Release/fluent-bit.exe /fluent-bit/bin/; `
100
+ Copy-Item -Path /src/build/bin/Release/fluent-bit.exe /fluent-bit/bin/
101
+
99
102
#
100
103
# Runtime Image - Windows Server Core
101
104
#
You can’t perform that action at this time.
0 commit comments