-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
24 lines (20 loc) · 916 Bytes
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
sudo: required
services:
- docker
language: bash
install:
- sudo apt update
- sudo apt install -y qemu qemu-user-static qemu-user binfmt-support
script:
- export DOMOTICZ_VERSION=$(curl https://releases.domoticz.com/releases/downloads.php | grep -oP '\d.\d{4}' | tail -1)
# prepare qemu
- docker run --rm --privileged multiarch/qemu-user-static:register --reset
# build image
- docker build -t gmaslowski/rpi-domoticz:${DOMOTICZ_VERSION}-arm .
# push image
- >
if [ "$TRAVIS_BRANCH" == "master" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
docker login -u="$DOCKER_USER" -p="$DOCKER_PASS"
docker push gmaslowski/rpi-domoticz:${DOMOTICZ_VERSION}-arm
docker run --rm -ti weshigbee/manifest-tool --username $DOCKER_USER --password $DOCKER_PASS push from-args --platforms linux/arm --target gmaslowski/rpi-domoticz:$DOMOTICZ_VERSION --template gmaslowski/rpi-domoticz:${DOMOTICZ_VERSION}-ARCH
fi