-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Make sure dart is actually available as a command Added some basic acceptance testing to the final stages of the image build to help us catch things like this in the future. * Update CHANGELOG
- Loading branch information
Showing
6 changed files
with
31 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
.idea | ||
.local-image |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,33 @@ | ||
NAME := cucumber/cucumber-build | ||
DEFAULT_PLATFORM = $(shell [ $$(arch) = "arm64" ] && echo "linux/arm64" || echo "linux/amd64") | ||
PLATFORMS ?= ${DEFAULT_PLATFORM} | ||
RUN_CMD ?=bash | ||
|
||
default: | ||
default: /tmp/.buildx-cache-new/index.json Dockerfile | ||
.PHONY: default | ||
|
||
/tmp/.buildx-cache-new/index.json: Dockerfile | ||
docker buildx build \ | ||
--cache-to="type=local,dest=/tmp/.buildx-cache-new" \ | ||
--cache-from="type=local,src=/tmp/.buildx-cache" \ | ||
--platform=${PLATFORMS} \ | ||
--tag ${NAME}:latest . | ||
.PHONY: default | ||
|
||
local: | ||
docker buildx build --platform=${PLATFORMS} --tag ${NAME}:latest --load . | ||
local: /tmp/.buildx-cache-new/index.json .local-image | ||
.PHONY: local | ||
|
||
docker-push: default | ||
echo "Deprecated. Please submit a pull request to the `release` branch to have your changes released." | ||
.PHONY: docker-push | ||
|
||
docker-run: local | ||
docker run \ | ||
--volume "${HOME}/.m2/repository":/home/cukebot/.m2/repository \ | ||
--user 1000 \ | ||
--rm \ | ||
-it ${NAME} \ | ||
bash | ||
.PHONY: | ||
$(1) | ||
|
||
.local-image: | ||
docker buildx build --platform=${PLATFORMS} --tag ${NAME}:latest --load . | ||
touch $@ | ||
|
||
clean: | ||
rm .local-image | ||
.PHONY: clean |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
set -e | ||
# | ||
# Runs some commands within the build image to validate basic expecations about what should be working. | ||
# | ||
|
||
which go || (echo "command 'go' not found" && exit 1) | ||
which dart || (echo "command 'dart' not found" && exit 1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters