diff --git a/Dockerfile b/Dockerfile index cb20b2746..18850f0cc 100644 --- a/Dockerfile +++ b/Dockerfile @@ -79,6 +79,10 @@ ADD .git/HEAD GIT_HEAD # Add all of the files! ADD . . +# If a pip package is licensed as GPL, fail the build. +# If this fails the build, change the last grep to be "grep -B 10 GPL" to see what package is GPLed. +RUN test -z "$(cat requirements.txt | grep -v "^-e" | awk -F'==' '{print $1}' | xargs pip show --disable-pip-version-check | grep -v LGPL | grep GPL)" + # Run the tests ARG RUN_TESTS=true ENV RUN_TESTS ${RUN_TESTS}