From 5fa414636b83df3f091adf4daed47fc3ca659dd3 Mon Sep 17 00:00:00 2001 From: "Ralf Th. Pietsch" Date: Wed, 22 Apr 2020 04:54:02 +0200 Subject: [PATCH] docker: remove git-objects from final docker image Removing git-objects, which are not needed, from final docker image, to make it smaller. Some files still need to be there, because Etherpad at startup uses them to discover its version number. --- .dockerignore | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/.dockerignore b/.dockerignore index 33331455..f7d90d4e 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,3 +1,22 @@ .hg + +# Remove the git objects, logs, etc. to make final image smaller. +# Some files still need to be in the .git directory, because Etherpad at +# startup uses them to discover its version number. +.git/branches +.git/COMMIT_EDITMSG +.git/config +.git/description +.git/FETCH_HEAD +.git/hooks +.git/index +.git/info +.git/logs +.git/objects +.git/ORIG_HEAD +.git/packed-refs +.git/refs/remotes/ +.gitignore + settings.json src/node_modules