mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-03-15 11:59:16 +01:00
gci: Only install one of elementsd or bitcoind
We were accidentally testing against `bitcoind` rather than `elementsd` which meant we believed everything was find, when in reality some tests broke. By only installing the required daemon we ensure that such a mixup causes a CI failure.
This commit is contained in:
parent
8ac63daf71
commit
36494b6a51
2 changed files with 18 additions and 7 deletions
23
.github/scripts/install-bitcoind.sh
vendored
23
.github/scripts/install-bitcoind.sh
vendored
|
@ -8,12 +8,21 @@ FILENAME="${DIRNAME}-x86_64-linux-gnu.tar.gz"
|
|||
EFILENAME="${EDIRNAME}-x86_64-linux-gnu.tar.gz"
|
||||
|
||||
cd /tmp/
|
||||
wget "https://bitcoincore.org/bin/bitcoin-core-${BITCOIN_VERSION}/${FILENAME}"
|
||||
wget "https://github.com/ElementsProject/elements/releases/download/elements-${ELEMENTS_VERSION}/${EFILENAME}"
|
||||
tar -xf "${FILENAME}"
|
||||
tar -xf "${EFILENAME}"
|
||||
sudo mv "${DIRNAME}"/bin/* "/usr/local/bin"
|
||||
sudo mv "${EDIRNAME}"/bin/* "/usr/local/bin"
|
||||
|
||||
# Since we inadvertently broke `elementsd` support in the past we only
|
||||
# want to download and enable the daemon that is actually going to be
|
||||
# used when running in CI. Otherwise we could end up accidentally
|
||||
# testing against `bitcoind` but still believe that we ran against
|
||||
# `elementsd`.
|
||||
if [ "$TEST_NETWORK" = "liquid-regtest" ]; then
|
||||
wget "https://github.com/ElementsProject/elements/releases/download/elements-${ELEMENTS_VERSION}/${EFILENAME}"
|
||||
tar -xf "${EFILENAME}"
|
||||
sudo mv "${EDIRNAME}"/bin/* "/usr/local/bin"
|
||||
rm -rf "${EFILENAME}" "${EDIRNAME}"
|
||||
else
|
||||
wget "https://bitcoincore.org/bin/bitcoin-core-${BITCOIN_VERSION}/${FILENAME}"
|
||||
tar -xf "${FILENAME}"
|
||||
sudo mv "${DIRNAME}"/bin/* "/usr/local/bin"
|
||||
rm -rf "${FILENAME}" "${DIRNAME}"
|
||||
fi
|
||||
|
||||
rm -rf "${FILENAME}" "${EFILENAME}" "${DIRNAME}" "${EDIRNAME}"
|
||||
|
|
2
.github/workflows/ci.yaml
vendored
2
.github/workflows/ci.yaml
vendored
|
@ -275,6 +275,8 @@ jobs:
|
|||
poetry install
|
||||
|
||||
- name: Install bitcoind
|
||||
env:
|
||||
TEST_NETWORK: ${{ matrix.TEST_NETWORK }}
|
||||
run: .github/scripts/install-bitcoind.sh
|
||||
|
||||
- name: Download build
|
||||
|
|
Loading…
Add table
Reference in a new issue