forked from ioBroker/ioBroker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.cirrus.yml
42 lines (38 loc) · 1.48 KB
/
.cirrus.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
freebsd_instance:
image_family: freebsd-14-0
task:
prepare_install_script:
- pkg install -y bash node npm libnghttp2 python sudo
install_script:
# remove download of library from installer script and fixer and source it manually
- |
sed '/# get and load the LIB => START/,/# get and load the LIB => END/d' installer.sh
sed '/# get and load the LIB => START/,/# get and load the LIB => END/d' fix_installation.sh
source ./installer_library.sh
# Install ioBroker
- |
sudo chmod +x ./installer.sh
./installer.sh
test_script:
# Test file permissions
- |
sudo chmod +x .github/testFiles.sh
.github/testFiles.sh
# Test if ioBroker starts by checking the admin adapter output
- curl --insecure http://127.0.0.1:8081 2> /dev/null | grep '<title>Admin</title>' &> /dev/null || exit 1
# Now test if adapters which require python can be installed
- iobroker url iobroker.lovelace
# Now test that the fixer does what it should
# Stop ioBroker processes before running the fixer
- IOB_DIR=`[ -d /opt/iobroker ] && echo "/opt/iobroker" || echo "/usr/local/iobroker"`
- cd $IOB_DIR
- node node_modules/iobroker.js-controller/iobroker.js stop
- sleep 60
#
- cd $TEST_DIR
# Run the fixer
- sudo chmod +x ./fix_installation.sh
- sudo env "PATH=$PATH" bash ./fix_installation.sh
# Test file permissions again...
- sudo chmod +x .github/testFiles.sh
- bash .github/testFiles.sh