Update travis with optional logs if build or install fail.
This commit is contained in:
parent
665dc4852c
commit
817d53e08e
17
.travis.yml
17
.travis.yml
@ -48,19 +48,18 @@ before_script:
|
|||||||
- sudo mv daemon.json /etc/docker/daemon.json
|
- sudo mv daemon.json /etc/docker/daemon.json
|
||||||
- sudo systemctl restart docker
|
- sudo systemctl restart docker
|
||||||
- docker version
|
- docker version
|
||||||
- sh -c 'while true; do echo "."; sleep 60; done' &
|
- sh -c 'while true; do echo "."; sleep 60; done' &; export TRAVIS_POLL_INSTALL=$!
|
||||||
- TRAVIS_POLL=$!
|
- docker build --platform=local -o . git://github.com/docker/buildx > logs 2>&1; export INSTALL_RESULT=$?
|
||||||
- docker build --platform=local -o . git://github.com/docker/buildx > /dev/null 2>&1
|
- kill -9 ${TRAVIS_POLL_INSTALL}
|
||||||
- kill -9 ${TRAVIS_POLL}
|
- if [ ! "$INSTALL_RESULT" = "0" ]; then tail -n 500 logs; fi
|
||||||
- mkdir -p ~/.docker/cli-plugins/
|
- mkdir -p ~/.docker/cli-plugins/
|
||||||
- mv buildx ~/.docker/cli-plugins/docker-buildx
|
- mv buildx ~/.docker/cli-plugins/docker-buildx
|
||||||
|
|
||||||
# Run the build and packaging and upload the built images to DockerHub
|
# Run the build and packaging and upload the built images to DockerHub
|
||||||
script:
|
script:
|
||||||
- docker buildx create --use --name insecure-builder --buildkitd-flags '--allow-insecure-entitlement security.insecure'
|
- docker buildx create --use --name insecure-builder --buildkitd-flags '--allow-insecure-entitlement security.insecure'
|
||||||
- sh -c 'while true; do echo "."; sleep 60; done' &
|
|
||||||
- TRAVIS_POLL=$!
|
|
||||||
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
|
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
|
||||||
- docker buildx build -t metacall/guix -o type=registry --allow security.insecure --build-arg METACALL_GUIX_VERSION="1.0.1" --build-arg METACALL_GUIX_ARCH="x86_64" . > logs 2>&1
|
- sh -c 'while true; do echo "."; sleep 60; done' &; export TRAVIS_POLL_BUILD=$!
|
||||||
- if [ ! "$?" = "0" ]; then tail -n 500 logs; fi
|
- docker buildx build -t metacall/guix -o type=registry --allow security.insecure --build-arg METACALL_GUIX_VERSION="1.0.1" --build-arg METACALL_GUIX_ARCH="x86_64" . > logs 2>&1; export BUILD_RESULT=$?
|
||||||
- kill -9 ${TRAVIS_POLL}
|
- kill -9 ${TRAVIS_POLL_BUILD}
|
||||||
|
- if [ ! "$BUILD_RESULT" = "0" ]; then tail -n 500 logs; fi
|
||||||
|
Loading…
Reference in New Issue
Block a user