#!/usr/bin/env groovy pipeline { agent { label 'nomad' } parameters { string(name: 'GIT_REPO_NAME', defaultValue: 'git.cronocide.net', description: 'The hostname of the git repository.') string(name: 'USERN', defaultValue: 'cronocide', description: 'The username of the user in the git repository.') } environment { WORKSPACE_PATH = "/opt/nomad/alloc/${NOMAD_ALLOC_ID}/${NOMAD_TASK_NAME}${WORKSPACE}" DESCRIPTION = "Another amazing piece of software written by Cronocide." } stages { stage('Copy') { steps { withEnv(['ACTION=cicd_copy']) { sh ( script: './build.sh') } } } } post { success { echo 'Pipeline succeeded.' } failure { echo 'Pipeline failed.' } } }