Because the .gitignore files are needed for configuring implicit excludes for rat, .dockerignore must not exclude these files when copying files into the image build context.