2021-05-06 14:11:47 +02:00
|
|
|
.PHONY: image test dbg clean build rebuild
|
2020-11-18 17:32:42 +01:00
|
|
|
.DEFAULT_GOAL := build
|
2020-11-18 17:16:37 +01:00
|
|
|
|
|
|
|
image:
|
2020-11-20 14:33:06 +01:00
|
|
|
docker build $(DOCKER_BUILD_OPTS) --tag netty-incubator-buffer:build .
|
2020-11-18 17:16:37 +01:00
|
|
|
|
|
|
|
test: image
|
|
|
|
docker run --rm --name build-container netty-incubator-buffer:build
|
|
|
|
|
|
|
|
dbg:
|
|
|
|
docker create --name build-container-dbg --entrypoint /bin/bash -t netty-incubator-buffer:build
|
|
|
|
docker start build-container-dbg
|
|
|
|
docker exec -it build-container-dbg bash
|
|
|
|
|
|
|
|
clean:
|
|
|
|
docker rm -fv build-container-dbg
|
2020-12-11 12:10:04 +01:00
|
|
|
docker rm -fv build-container
|
2020-11-18 17:16:37 +01:00
|
|
|
|
2021-04-27 15:06:43 +02:00
|
|
|
clean-layer-cache:
|
|
|
|
docker builder prune -f -a
|
|
|
|
|
2020-11-18 17:16:37 +01:00
|
|
|
build: image
|
|
|
|
docker create --name build-container netty-incubator-buffer:build
|
2021-04-09 10:15:00 +02:00
|
|
|
mkdir -p target/container-output
|
|
|
|
docker start -a build-container || (docker cp build-container:/home/build target/container-output && false)
|
|
|
|
docker wait build-container || (docker cp build-container:/home/build target/container-output && false)
|
2020-11-18 17:16:37 +01:00
|
|
|
docker cp build-container:/home/build/target .
|
2021-05-21 14:34:33 +02:00
|
|
|
docker cp build-container:/home/build/buffer-api/target .
|
|
|
|
docker cp build-container:/home/build/buffer-memseg/target .
|
|
|
|
docker cp build-container:/home/build/buffer-tests/target .
|
2020-11-18 17:16:37 +01:00
|
|
|
docker rm build-container
|
2021-04-27 15:06:43 +02:00
|
|
|
|
|
|
|
rebuild: clean clean-layer-cache build
|