cloud66-oss/habitus

v1.0.5 does not run in docker:19.03.6

bassco opened this issue · 3 comments

Issue:

When installing v1.0.5 into docker:19.03.6 container the binary is unable to be launched

# habitus -version
sh: habitus: not found
# md5sum /usr/local/bin/habitus
4f89ce1fe21429117c1b4b65b92d0bf8  /usr/local/bin/habitus

Prior versions 1.0.3 and 1.0.4 are successful.

Steps to reproduce:

export HABITUS_VERSION=1.0.5
mkdir -p fred && cd fred
(
          echo "FROM docker:19.03.6";
          echo "ARG HABITUS_VERSION=1.0.5";
          echo "RUN wget -O /usr/local/bin/habitus https://github.com/cloud66-oss/habitus/releases/download/\${HABITUS_VERSION}/habitus_linux_amd64";
          echo "RUN chmod a+x /usr/local/bin/habitus";
        ) > Dockerfile.habitus;
docker build -t habitus:${HABITUS_VERSION} -f Dockerfile.habitus .
docker run --rm -ti habitus:${HABITUS_VERSION} habitus -version
/usr/local/bin/docker-entrypoint.sh: exec: line 61: habitus: not found

Changing HABITUS_VERSION to 1.0.4 yields the correct result:

export HABITUS_VERSION=1.0.4
docker build -t habitus:${HABITUS_VERSION} --build-arg HABITUS_VERSION=${HABITUS_VERSION} -f Dockerfile.habitus .
docker run --rm -ti habitus:${HABITUS_VERSION} habitus -version
Habitus - vv1.0.4 (c) 2017 Cloud 66 Inc.
khash commented

Does this work with 1.0.5 on a Docker version other than 19.03.6?

Just tried docker:18

  • failed for 1.0.5
  • passed for 1.0.4
  • passed for 1.0.3

I suspect the build for 1.0.5 for linux_amd64 is broken
1.0.5 for mac/darwin_amd64 works

@khash - I've done some more testing

version container OS Working
1.0.5 debian/ubuntu ✔️
1.0.5 alpine ✖️
1.0.4 debian/ubuntu ✔️
1.0.4 alpine ✔️

Something must have changed in the build system for alpine to have stopped working