pipeline {
    agent {
        label "backend-agent"
    }

    environment {
        PROJECT_NAME = "application-skeleton"
        PROJECT_CREDENTIALS = credentials("applicationSkeleton.credentials")
    }

    stages {
        stage("Doing something") {
            steps() {
                script {
                    pipe = setupWebhookPipeline()

                    def dateTag = sh(
                        script: 'date -u +%Y%m%d%H%M%S',
                        returnStdout: true
                    ).trim()

                    env.VERSION = "v1.2.3-${dateTag}"
                }
            }
        }
    }
    post {
        success {

        }
        unsuccessful {

        }
    }
}
