forked from nixel2007/vanessa-behavior-new
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
43 lines (37 loc) · 1.8 KB
/
.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
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
sudo: required
services:
- docker
before_install:
# Fetch base image and build new container
- wget -nv --continue -O - $URL_TARCLIENT | xz -d | docker load
#- wget --continue -O ./build/client32.tar.xz $URL_TARCLIENT
#- xz -dc ./build/client32.tar.xz | docker load
- docker pull wernight/ngrok
- docker images | grep onec
script:
- sudo docker run --detach -e XVFB_RESOLUTION=1920x1080x24 --volume="${PWD}":/home/ubuntu/code onec32/client:8.3.10.2466 client > /tmp/container_id
- sudo docker ps && sleep 5
- sudo docker run -d -p 4040:4040 --link "$(cat /tmp/container_id)":http wernight/ngrok ngrok http http:6080 > /tmp/container_idngrok
- sleep 5 && echo $(curl -s http://127.0.0.1:4040/status | grep -P "http://.*?ngrok.io" -oh)"/vnc_auto.html"
- sudo docker exec -u ubuntu "$(cat /tmp/container_id)" /bin/bash -c "cd /home/ubuntu/code; DISPLAY=:1.0 sudo opm install && sudo opm update -all"
- sudo docker exec -u ubuntu "$(cat /tmp/container_id)" /bin/bash -c "cd /home/ubuntu/code; DISPLAY=:1.0 sudo opm run init"
- sudo docker exec -u ubuntu "$(cat /tmp/container_id)" /bin/bash -c "cd /home/ubuntu/code; DISPLAY=:1.0 sudo opm build ./"
# Clean up
- sudo docker stop "$(cat /tmp/container_id)"
- sudo docker stop "$(cat /tmp/container_idngrok )"
- pushd ./build; sudo tar -czf ../vanessa-behavior.tar.gz ./vanessa-behavior.epf ./lib/ ./features/libraries ./vendor ./plugins ./locales; popd
- pushd ./build; sudo zip -r ../vanessa-behavior.zip ./vanessa-behavior.epf ./lib/ ./features/libraries ./vendor ./plugins ./locales; popd
notifications:
email: true
deploy:
provider: releases
api_key:
secure: "$APIPUBLISHKEY"
file:
- "vanessa-behavior.tar.gz"
- "vanessa-behavior.zip"
- "vanessa-behavior-*.ospx"
file_glob: "true"
skip_cleanup: true
on:
tags: true