Skip to content

Commit

Permalink
fix: Remove cacheing
Browse files Browse the repository at this point in the history
Signed-off-by: Gordon Smith <[email protected]>
  • Loading branch information
GordonSmith committed Jul 12, 2023
1 parent 6804a2e commit b9cba61
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
*
**/*

# Folders
!.git
!overlays
!ports
!scripts
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/prebuild-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,5 +79,4 @@ jobs:
tags: |
hpccsystems/platform-build-base-${{ matrix.image }}:${{ steps.vars.outputs.sha_short }}
hpccsystems/platform-build-base-${{ matrix.image }}:${{ steps.vars.outputs.vcpkg_tag }}
cache-from: type=registry,ref=hpccbuilds/platform-build-base-${{ matrix.image }}:${{ steps.vars.outputs.vcpkg_branch }}
cache-to: type=registry,ref=hpccbuilds/platform-build-base-${{ matrix.image }}:${{ steps.vars.outputs.vcpkg_branch }},mode=max
24 changes: 14 additions & 10 deletions dockerfiles/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,33 +8,37 @@ export $(grep -v '^#' $SCRIPT_DIR/../.env | xargs -d '\r' | xargs -d '\n') > /de
GITHUB_ACTOR="${GITHUB_ACTOR:-hpcc-systems}"
GITHUB_TOKEN="${GITHUB_TOKEN:-none}"
GITHUB_REF=$(git rev-parse --short=8 HEAD)
GITHUB_BRANCH=$(git rev-parse --abbrev-ref HEAD)
DOCKER_USERNAME="${DOCKER_USERNAME:-hpccbuilds}"
DOCKER_PASSWORD="${DOCKER_PASSWORD:-none}"

echo "SCRIPT_DIR: $SCRIPT_DIR"
echo "GITHUB_ACTOR: $GITHUB_ACTOR"
echo "GITHUB_TOKEN: $GITHUB_TOKEN"
echo "GITHUB_REF: $GITHUB_REF"
echo "GITHUB_BRANCH: $GITHUB_BRANCH"
echo "DOCKER_USERNAME: $DOCKER_USERNAME"
echo "DOCKER_PASSWORD: $DOCKER_PASSWORD"

# docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD

function doBuild() {
docker build --progress plain --pull --rm -f "$SCRIPT_DIR/$1.dockerfile" \
-t hpccsystems/platform-build-base-$1:$GITHUB_REF \
-t hpccsystems/platform-build-base-$1:latest \
docker build --progress plain -f "$SCRIPT_DIR/$1.dockerfile" \
--build-arg GITHUB_ACTOR=$GITHUB_ACTOR \
--build-arg GITHUB_TOKEN=$GITHUB_TOKEN \
-t hpccsystems/platform-build-base-$1:$GITHUB_REF \
-t hpccsystems/platform-build-base-$1:$GITHUB_BRANCH \
"$SCRIPT_DIR/.."

# docker push hpccsystems/platform-build-base-$1:$GITHUB_REF
# docker push hpccsystems/platform-build-base-$1:latest
}

doBuild amazonlinux
doBuild ubuntu-22.10
# doBuild ubuntu-22.04
doBuild ubuntu-20.04
doBuild ubuntu-18.04
doBuild centos-8
doBuild centos-7
doBuild centos-7 &
doBuild centos-8 &
doBuild amazonlinux &
doBuild ubuntu-22.10 &
doBuild ubuntu-22.04 &
doBuild ubuntu-20.04 &

wait

0 comments on commit b9cba61

Please sign in to comment.