mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
15674c5fb7
Signed-off-by: Jessica Frazelle <acidburn@docker.com>
17 lines
403 B
Bash
17 lines
403 B
Bash
#!/bin/bash
|
|
set -e
|
|
|
|
# Build a C binary for cloning a userns for seccomp tests
|
|
# and compile it for target daemon
|
|
|
|
dir="$DEST/userns-test"
|
|
mkdir -p "$dir"
|
|
(
|
|
if [ "$(go env GOOS)" = "linux" ]; then
|
|
cd "$dir"
|
|
gcc -g -Wall -static ../../../../contrib/userns-test/main.c -o ./userns-test
|
|
cp ../../../../contrib/userns-test/Dockerfile .
|
|
docker build -qt userns-test . > /dev/null
|
|
fi
|
|
)
|
|
rm -rf "$dir"
|