ci: identify runner in each stage

This commit is contained in:
Martin Weinelt 2020-04-07 15:34:40 +02:00 committed by David Bauer
parent 4cd26d860a
commit d9ea281436

View File

@ -11,12 +11,14 @@ pipeline {
stage('lint-lua') { stage('lint-lua') {
agent { label 'gluon-docker' } agent { label 'gluon-docker' }
steps { steps {
sh label: 'Identify runner', script: 'echo $SLAVE_NAME'
sh 'make lint-lua' sh 'make lint-lua'
} }
} }
stage('lint-sh') { stage('lint-sh') {
agent { label 'gluon-docker-v1' } agent { label 'gluon-docker-v1' }
steps { steps {
sh label: 'Identify runner', script: 'echo $SLAVE_NAME'
sh 'make lint-sh' sh 'make lint-sh'
} }
} }
@ -25,12 +27,14 @@ pipeline {
stage('docs') { stage('docs') {
agent { label 'gluon-docker' } agent { label 'gluon-docker' }
steps { steps {
sh label: 'Identify runner', script: 'echo $SLAVE_NAME'
sh 'make -C docs html' sh 'make -C docs html'
} }
} }
stage('build') { stage('build') {
agent { label 'gluon-docker' } agent { label 'gluon-docker' }
steps { steps {
sh label: 'Identify runner', script: 'echo $SLAVE_NAME'
sh 'make update' sh 'make update'
sh 'test -d /dl_cache && ln -s /dl_cache openwrt/dl || true' sh 'test -d /dl_cache && ln -s /dl_cache openwrt/dl || true'
sh 'make -j$(nproc) V=s' sh 'make -j$(nproc) V=s'
@ -43,6 +47,7 @@ pipeline {
TMUX = "notmux" TMUX = "notmux"
} }
steps { steps {
sh label: 'Identify runner', script: 'echo $SLAVE_NAME'
unstash 'gluon-x86-64-factory' unstash 'gluon-x86-64-factory'
sh label: 'Unpack image', script: 'gunzip -cd ./output/images/factory/*x86-64*.img.gz > ./image.img' sh label: 'Unpack image', script: 'gunzip -cd ./output/images/factory/*x86-64*.img.gz > ./image.img'
sh label: 'Print python environment', script: 'python3 -m pip freeze' sh label: 'Print python environment', script: 'python3 -m pip freeze'