pipeline { agent any tools { nodejs 'nodejs' // Ensure this matches the name defined in Jenkins } stages { stage('Check Node.js Version') { steps { script { sh 'node --version' } } } } }