mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-22 08:34:20 +01:00
Merge pull request #45 from cdecker/travis-ci
Adding Travis-CI configuration
This commit is contained in:
26
.travis.yml
Normal file
26
.travis.yml
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
sudo: required
|
||||||
|
dist: trusty
|
||||||
|
language: c
|
||||||
|
before_install:
|
||||||
|
- sudo add-apt-repository ppa:bitcoin/bitcoin -y
|
||||||
|
- sudo add-apt-repository ppa:ondrej/pkg-nlnetlabs -y || true # This fails due to UTF-8 in the author's name...
|
||||||
|
- sudo add-apt-repository ppa:chris-lea/libsodium -y
|
||||||
|
- sudo apt-get -qq update
|
||||||
|
install:
|
||||||
|
- sudo apt-get install -y --no-install-recommends bitcoind build-essential automake eatmydata net-tools libtool libprotobuf-c-dev libsodium-dev libsqlite3-dev valgrind protobuf-c-compiler libgmp-dev
|
||||||
|
- git clone https://github.com/luke-jr/libbase58.git libbase58; cd libbase58; ./autogen.sh; ./configure; make; sudo make install; cd ..
|
||||||
|
- git clone https://github.com/rustyrussell/lightning-rfc.git ../lightning-rfc
|
||||||
|
compiler:
|
||||||
|
- gcc
|
||||||
|
script:
|
||||||
|
- make clean
|
||||||
|
- make
|
||||||
|
- make full-check
|
||||||
|
after_failure:
|
||||||
|
- sudo killall lightningd
|
||||||
|
- sudo kill `ps aux | grep lightningd | grep -v grep | awk '{print $2}'`;
|
||||||
|
- tar -cvjf /tmp/travis-run.tar.bz2 /tmp/lightning.*.?;
|
||||||
|
- curl --upload-file /tmp/travis-run.tar.bz2 https://transfer.sh/travis-run.tar.bz2;
|
||||||
|
env:
|
||||||
|
global:
|
||||||
|
- LD_LIBRARY_PATH=/usr/local/lib
|
||||||
@@ -80,6 +80,8 @@ check lcli3 "getpeers | $FGREP \"\\\"our_amount\\\" : $(($HTLC_AMOUNT - $NO_HTLC
|
|||||||
if [ "$RECONNECT" = restart ]; then
|
if [ "$RECONNECT" = restart ]; then
|
||||||
echo RESTARTING NODE3
|
echo RESTARTING NODE3
|
||||||
$LCLI3 -- dev-restart $LIGHTNINGD3 >/dev/null 2>&1 || true
|
$LCLI3 -- dev-restart $LIGHTNINGD3 >/dev/null 2>&1 || true
|
||||||
|
sleep 5
|
||||||
|
$LCLI2 -- dev-restart $LIGHTNINGD2 >/dev/null 2>&1 || true
|
||||||
if ! check "$LCLI3 getpeers 2>/dev/null | tr -s '\012\011\" ' ' ' | fgrep -q 'connected : true'"; then
|
if ! check "$LCLI3 getpeers 2>/dev/null | tr -s '\012\011\" ' ' ' | fgrep -q 'connected : true'"; then
|
||||||
echo "Failed to reconnect!">&2
|
echo "Failed to reconnect!">&2
|
||||||
exit 1
|
exit 1
|
||||||
|
|||||||
Reference in New Issue
Block a user