To reduce duplication of effort in my docker containers, I'd like to run pipeline steps both in a docker container, and with Jenkins tool installations available.
This naïve attempt doesn't work - npm
is not found
pipeline {
agent { dockerfile true }
tools { nodejs 'LTS' }
stages {
stage('NPM') {
steps { sh 'npm install-ci-test' }
}
}
}
Is this possible?