Skip to content

Instantly share code, notes, and snippets.

@davehunt
Last active February 28, 2018 20:51
Show Gist options
  • Save davehunt/f70de129a55bfd9664e3223c2d4c6c88 to your computer and use it in GitHub Desktop.
Save davehunt/f70de129a55bfd9664e3223c2d4c6c88 to your computer and use it in GitHub Desktop.
#!/usr/bin/env groovy
pipeline {
agent none
stages {
stage('clone') {
agent any
steps {
checkout([
$class: 'GitSCM',
branches: [[name: 'master']],
extensions: [[$class: 'RelativeTargetDirectory', relativeTargetDir: 'webpagetest-api']],
userRemoteConfigs: [[url: 'https://github.com/marcelduran/webpagetest-api']]])
}
}
stage('test') {
agent {
dockerfile { dir 'webpagetest-api' }
}
environment {
WEB_PAGE_TEST = credentials('WEB_PAGE_TEST')
WEBPAGETEST_SERVER = "https://${WEB_PAGE_TEST}@wpt-api.stage.mozaws.net/"
}
steps {
sh '/usr/src/app/bin/webpagetest test "https://latest.dev.lcip.org/?service=sync&entrypoint=firstrun&context=fx_desktop_v3" -l "us-east-1:Firefox" -r 9 --first --poll --reporter json > fxa-homepage.json'
}
post {
always {
archiveArtifacts 'fxa-homepage.json'
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment