Last active
March 25, 2022 17:56
-
-
Save slutske22/de32400616ba9b0c583ad5d0eb15ddc1 to your computer and use it in GitHub Desktop.
sorry-cypress-jenkinsfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
stage ('Cypress'){ | |
parallel { | |
stage('Cypress 1') { | |
agent { | |
node { | |
label 'agent-1' | |
} | |
} | |
steps { | |
sh 'npm install --silent' | |
sh 'npm start & npx wait-on http://localhost:3000' | |
sh "CYPRESS_API_URL=\"http://Sorry-Cypress-Instance-IP:1234/\" npx cy2 run --record --key XXX --parallel --ci-build-id env.BUILD_ID" | |
} | |
} | |
stage('Cypress 2') { | |
agent { | |
node { | |
label 'agent-2' | |
} | |
} | |
steps { | |
sh 'npm install --silent' | |
sh 'npm start & npx wait-on http://localhost:3000' | |
sh "CYPRESS_API_URL=\"http://Sorry-Cypress-Instance-IP:1234/\" npx cy2 run --record --key XXX --parallel --ci-build-id env.BUILD_ID" | |
} | |
} | |
stage('Cypress 3') { | |
agent { | |
node { | |
label 'agent-3' | |
} | |
} | |
steps { | |
sh 'npm install --silent' | |
sh 'npm start & npx wait-on http://localhost:3000' | |
sh "CYPRESS_API_URL=\"http://Sorry-Cypress-Instance-IP:1234/\" npx cy2 run --record --key XXX --parallel --ci-build-id env.BUILD_ID" | |
} | |
} | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment