Update the script for testing in docker container:

- don't require bash
  - mark appimage stage
  - use --no-cache if docker build fails
  - remove container after running the tests
  - use tty for colorful output
This commit is contained in:
Lee Miller 2022-04-05 01:35:35 +03:00
parent fd7a6f8fee
commit 60fd56748f
Signed by untrusted user: lee.miller
GPG Key ID: 4F97A5EA88F4AB63

View File

@ -1,5 +1,13 @@
#!/bin/bash #!/bin/sh
docker build --target travis -t pybm -f packages/docker/Dockerfile.bionic . DOCKERFILE=packages/docker/Dockerfile.bionic
docker run pybm
# explicitly mark appimage stage because it builds in any case
docker build --target appimage -t pybm/appimage -f $DOCKERFILE .
if [ $? -gt 0 ]; then
docker build --no-cache --target appimage -t pybm/appimage -f $DOCKERFILE .
fi
docker build --target tox -t pybm/tox -f $DOCKERFILE .
docker run --rm -t pybm/tox