1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Makefile: Run containers with --init for proper signal handling

This makes it possible to Ctrl-C tests and builds again.   Zombie
processes will also be reaped correctly.

Signed-off-by: Euan Harris <euan.harris@docker.com>
This commit is contained in:
Euan Harris 2018-07-10 10:20:44 +01:00
parent 9d758090cf
commit c699a1215e
2 changed files with 1 additions and 12 deletions

View file

@ -4,7 +4,7 @@ dockerbuildargs ?= --target dev - < Dockerfile
dockerargs ?= --privileged -v $(shell pwd):/go/src/github.com/docker/libnetwork -w /go/src/github.com/docker/libnetwork
build_image=libnetworkbuild
container_env = -e "INSIDECONTAINER=-incontainer=true"
docker = docker run --rm -it ${dockerargs} $$EXTRA_ARGS ${container_env} ${build_image}
docker = docker run --rm -it --init ${dockerargs} $$EXTRA_ARGS ${container_env} ${build_image}
CROSS_PLATFORMS = linux/amd64 linux/386 linux/arm windows/amd64
PACKAGES=$(shell go list ./... | grep -v /vendor/)
export PATH := $(CURDIR)/bin:$(PATH)

View file

@ -1,11 +0,0 @@
#!/usr/bin/env bash
set -e
function raise()
{
kill -$1 0
}
trap "raise SIGINT" SIGINT
make $1