From 699c3aadf25944975a390fa1bd333eb1ef4b5d89 Mon Sep 17 00:00:00 2001 From: Thomas Orozco Date: Sun, 15 Mar 2015 16:56:12 +0100 Subject: [PATCH] Remove the static build for now The static build doesn't build with clang, and its usefulness is dubious for the time being considering the only requirement is glibc. --- .travis.yml | 1 - CMakeLists.txt | 3 --- Dockerfile | 2 +- README.md | 11 ----------- ci/run_build.sh | 2 +- ddist.sh | 6 ++---- test/test.py | 2 +- 7 files changed, 5 insertions(+), 22 deletions(-) diff --git a/.travis.yml b/.travis.yml index 02135ed..73ede53 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,7 +12,6 @@ deploy: secure: Yk90ANpSPv1iJy8QDXCPwfaSmEr/WIJ3bzhQ6X8JvZjfrwTosbh0HrUzQyeac3nyvNwj7YJRssolOFc21IBKPpCFTZqYxSkuLPU6ysG4HGHgN6YJhOMm4mG4KKJ6741q3DJendhZpalBhCEi+NcZK/PCSD97Vl4OqRjBUged0fs= file: - "./tini" - - "./tini-static" on: repo: krallin/tini tags: true diff --git a/CMakeLists.txt b/CMakeLists.txt index ed38efe..4f7efc1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -22,6 +22,3 @@ configure_file ( include_directories ("${PROJECT_BINARY_DIR}") add_executable (tini tini.c) - -add_executable (tini-static tini.c) -set_target_properties (tini-static PROPERTIES LINK_FLAGS "-static") diff --git a/Dockerfile b/Dockerfile index c533af4..438fba9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ FROM ubuntu RUN apt-get update \ - && apt-get install --no-install-recommends --yes build-essential git gdb valgrind cmake \ + && apt-get install --no-install-recommends --yes build-essential git gdb valgrind cmake clang \ && rm -rf /var/lib/apt/lists/* ADD . /tini diff --git a/README.md b/README.md index 69299ef..1b783e8 100644 --- a/README.md +++ b/README.md @@ -47,22 +47,11 @@ Assuming your entrypoint was `/docker-entrypoint.sh`, then you would use: ENTRYPOINT ["/tini", "--", "/docker-entrypoint.sh"] -### Statically-Linked Version ### - -Tini has very few dependencies (it only depends on libc), but if your -container fails to start, you might want to consider using the statically-built -version instead: - - ADD https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini-static /tini - - ### Size Considerations ### Tini is a very small file (in the 10KB range), so it doesn't add much weight to your container. -The statically-linked version is bigger, but still < 1M. - ### Building Tini ### diff --git a/ci/run_build.sh b/ci/run_build.sh index 0445cb1..9a3e158 100755 --- a/ci/run_build.sh +++ b/ci/run_build.sh @@ -11,7 +11,7 @@ make # Smoke tests (actual tests need Docker to run; they don't run within the CI environment) # Success -for tini in ./tini ./tini-static; do +for tini in ./tini; do echo "Testing $tini with: true" $tini -vvvv true diff --git a/ddist.sh b/ddist.sh index cca05dc..0795e57 100755 --- a/ddist.sh +++ b/ddist.sh @@ -14,12 +14,10 @@ BIN="tini" docker build -t "${IMG}" . -# Smoke tests +# Smoke test docker run -it --rm --entrypoint="/tini/${BIN}" "${IMG}" "-h" "--" "true" -docker run -it --rm --entrypoint="/tini/${BIN}-static" "${IMG}" "-h" "--" "true" -# Copy the binaries +# Copy the binary docker run -it --entrypoint="/bin/true" --name="${NAME}" "${IMG}" docker cp "${NAME}:/tini/${BIN}" "${DIST_DIR}" -docker cp "${NAME}:/tini/${BIN}-static" "${DIST_DIR}" docker rm "${NAME}" diff --git a/test/test.py b/test/test.py index 6cd331a..6e04bfb 100644 --- a/test/test.py +++ b/test/test.py @@ -61,7 +61,7 @@ if __name__ == "__main__": root = os.path.abspath(os.path.join(os.path.dirname(__file__), "..")) - for entrypoint in ["/tini/tini", "/tini/tini-static"]: + for entrypoint in ["/tini/tini"]: base_cmd = [ "docker", "run",