diff --git a/.dockerignore b/.dockerignore index 15479142e..86ed5ed2a 100644 --- a/.dockerignore +++ b/.dockerignore @@ -5,7 +5,6 @@ test/data/registry venv .git !.git/HEAD -!.git/refs .gitignore Bobfile README.md diff --git a/Dockerfile b/Dockerfile index 135a262cd..6b7cbf557 100644 --- a/Dockerfile +++ b/Dockerfile @@ -54,10 +54,8 @@ RUN mkdir static/fonts static/ldn RUN venv/bin/python -m external_libraries RUN mkdir /usr/local/nginx/logs/ -# We exclude everything except .git/{HEAD,refs} in .dockerignore so we don't -# leak data into the image layer. -RUN cat ".git/$( cat .git/HEAD | cut -d' ' -f 2 )" > GIT_HEAD -RUN rm -fr .git +# TODO(ssewell): only works on a detached head, make work with ref +RUN cat .git/HEAD > GIT_HEAD # Run the tests RUN TEST=true venv/bin/python -m unittest discover -f