Skip to content
This repository has been archived by the owner on Jan 14, 2022. It is now read-only.

Commit

Permalink
Test against Core 1.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
francoilol committed Nov 30, 2018
1 parent 8569e3a commit 79dd909
Showing 1 changed file with 44 additions and 23 deletions.
67 changes: 44 additions & 23 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
pipeline {
agent { node { label 'lisk-explorer' } }
environment {
LISK_VERSION = '1.0.0-beta.9.2'
LISK_CORE_VERSION = '1.3.0'
EXPLORER_PORT = "604$EXECUTOR_NUMBER"
LISK_HOST = 'localhost'
REDIS_DB = "$EXECUTOR_NUMBER"
Expand Down Expand Up @@ -45,25 +45,46 @@ pipeline {
}
stage ('Start Lisk') {
steps {
dir("$WORKSPACE/$BRANCH_NAME/") {
ansiColor('xterm') {
sh '''
rsync -axl --delete ~/lisk-docker/examples/development/ ./
cp ~/blockchain_explorer.db.gz ./blockchain.db.gz
make coldstart
'''
// show some build-related info
sh '''
sha1sum ./blockchain.db.gz
docker-compose config
docker-compose ps
'''
// Explorer needs the topAccounts feature to be enabled
sh '''
docker-compose exec -T lisk sed -i -r -e 's/(\\s*"topAccounts":)\\s*false,/\\1 true,/' config.json
docker-compose restart lisk
'''
}
dir('lisk') {
checkout([$class: 'GitSCM',
branches: [[name: "v${env.LISK_CORE_VERSION}" ]],
userRemoteConfigs: [[url: 'https://github.com/LiskHQ/lisk']]])
}

ansiColor('xterm') {
sh '''#!/bin/bash -xe
rm -rf $WORKSPACE/$BRANCH_NAME/
cp -rf $WORKSPACE/lisk/docker/ $WORKSPACE/$BRANCH_NAME/
wget -nv https://downloads.lisk.io/lisk-explorer/dev/dev_blockchain.db.gz -O $WORKSPACE/$BRANCH_NAME/dev_blockchain.db.gz
cd $WORKSPACE/$BRANCH_NAME
cp .env.development .env
# random port assignment
cat <<EOF >docker-compose.override.yml
version: "2"
services:
lisk:
ports:
- \\${ENV_LISK_HTTP_PORT}
- \\${ENV_LISK_WS_PORT}
EOF
ENV_LISK_VERSION="$LISK_CORE_VERSION" make coldstart
'''
// show some build-related info
sh '''
cd $WORKSPACE/$BRANCH_NAME
sha1sum dev_blockchain.db.gz
docker-compose config
docker-compose ps
'''
// Explorer needs the topAccounts feature to be enabled
sh '''
cd $WORKSPACE/$BRANCH_NAME
docker-compose exec -T lisk sed -i -r -e 's/(\\s*"topAccounts":)\\s*false,/\\1 true,/' config.json
docker-compose restart lisk
'''
}
}
}
Expand Down Expand Up @@ -93,9 +114,9 @@ pipeline {
// stage ('Run E2E tests') {
// steps {
// wrap([$class: 'Xvfb']) {
// nvm(getNodejsVersion()) {
// sh 'npm run e2e -- --params.baseURL http://localhost:$EXPLORER_PORT'
// }
// nvm(getNodejsVersion()) {
// sh 'npm run e2e -- --params.baseURL http://localhost:$EXPLORER_PORT'
// }
// }
// }
// }
Expand Down

0 comments on commit 79dd909

Please sign in to comment.