The current code is running flake8 from a container to check every
python file changed by a PR.
The actual code doesn't import the tox.ini of ceph-container which
specify a particular configuration like "max-line-length = 99"
This lead to a situation where a dev which runs flake on his dev env
have a flake reporting now failures while flake from the CI fails.
So this patch is about adding project's tox.ini inside the container to
insure flake is using it.
while read -r filename; do
pushd "$(dirname "$filename")"
file=$(basename "$filename")
- sudo docker run --rm -v "$(pwd)"/"$file":/"$file" eeacms/flake8 /"$file"
+ sudo docker run --rm -v "$(pwd)"/tox.ini:/tox.ini -v "$(pwd)"/"$file":/"$file" eeacms/flake8 /"$file"
popd
done
return $?