Skip to content

Commit c81c101

Browse files
committed
Fix docker github pipeline
Signed-off-by: Mitch Gaffigan <mitch.gaffigan@comcast.net>
1 parent 741827b commit c81c101

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

.github/workflows/build.yaml

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ on:
88
branches:
99
- main
1010

11+
env:
12+
BUILDKIT_PROGRESS: plain
13+
1114
jobs:
1215
event_file:
1316
name: "Event File"
@@ -28,6 +31,9 @@ jobs:
2831
steps:
2932
- uses: actions/checkout@v4
3033

34+
- name: Set up Docker Buildx
35+
uses: docker/setup-buildx-action@v3
36+
3137
- name: Set build metadata
3238
id: meta
3339
run: |
@@ -41,22 +47,21 @@ jobs:
4147
4248
- name: Build Alpine production image
4349
run: |
44-
rm -rf /tmp/oie-buildx-cache /tmp/oie-buildx-cache-new
4550
docker buildx build \
4651
--build-arg "ANT_BUILD_ARGS=${ANT_BUILD_ARGS}" \
47-
--cache-to type=local,dest=/tmp/oie-buildx-cache-new,mode=max \
52+
--cache-from type=gha,scope=oie-build \
53+
--cache-to type=gha,scope=oie-build,mode=max \
4854
--target jre-run \
4955
-t "${{ steps.meta.outputs.alpine_server_image }}" \
5056
--load \
5157
.
5258
5359
- name: Build Ubuntu production image
5460
run: |
55-
cp -R /tmp/oie-buildx-cache-new /tmp/oie-buildx-cache
5661
docker buildx build \
5762
--build-arg "ANT_BUILD_ARGS=${ANT_BUILD_ARGS}" \
58-
--cache-from type=local,src=/tmp/oie-buildx-cache \
59-
--cache-to type=local,dest=/tmp/oie-buildx-cache-new,mode=max \
63+
--cache-from type=gha,scope=oie-build \
64+
--cache-to type=gha,scope=oie-build,mode=max \
6065
--target jdk-run \
6166
-t "${{ steps.meta.outputs.ubuntu_server_image }}" \
6267
--load \
@@ -65,10 +70,10 @@ jobs:
6570
- name: Export build artifacts and test results
6671
run: |
6772
rm -rf docker-build-output
68-
cp -R /tmp/oie-buildx-cache-new /tmp/oie-buildx-cache
6973
docker buildx build \
7074
--build-arg "ANT_BUILD_ARGS=${ANT_BUILD_ARGS}" \
71-
--cache-from type=local,src=/tmp/oie-buildx-cache \
75+
--cache-from type=gha,scope=oie-build \
76+
--cache-to type=gha,scope=oie-build,mode=max \
7277
--target build-output-export \
7378
--output type=local,dest=docker-build-output \
7479
.

0 commit comments

Comments
 (0)