From 886a954823253bb3a3fdf31aebe92c297ec79a4b Mon Sep 17 00:00:00 2001 From: Yuxiang Zhu Date: Oct 10 2018 02:57:57 +0000 Subject: Remove doc and container push stages from rcm-tools Jenkins job As the new pipeline jobs are taking over the container and doc push responsibility, those stages are removed from rcm-tools Jenkins job. --- diff --git a/Jenkinsfile b/Jenkinsfile index 2424312..2863e71 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -79,29 +79,6 @@ node('fedora') { sh 'make -C docs html' archiveArtifacts artifacts: 'docs/_build/html/**' } - if (scmVars.GIT_BRANCH == 'origin/master') { - stage('Publish Docs') { - sshagent (credentials: ['pagure-waiverdb-deploy-key']) { - sh ''' - mkdir -p ~/.ssh/ - touch ~/.ssh/known_hosts - ssh-keygen -R pagure.io - echo 'pagure.io,140.211.169.204 ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC198DWs0SQ3DX0ptu+8Wq6wnZMrXUCufN+wdSCtlyhHUeQ3q5B4Hgto1n2FMj752vToCfNTn9mWO7l2rNTrKeBsELpubl2jECHu4LqxkRVihu5UEzejfjiWNDN2jdXbYFY27GW9zymD7Gq3u+T/Mkp4lIcQKRoJaLobBmcVxrLPEEJMKI4AJY31jgxMTnxi7KcR+U5udQrZ3dzCn2BqUdiN5dMgckr4yNPjhl3emJeVJ/uhAJrEsgjzqxAb60smMO5/1By+yF85Wih4TnFtF4LwYYuxgqiNv72Xy4D/MGxCqkO/nH5eRNfcJ+AJFE7727F7Tnbo4xmAjilvRria/+l' >>~/.ssh/known_hosts - rm -rf docs-on-pagure - git clone ssh://git@pagure.io/docs/waiverdb.git docs-on-pagure - rm -r docs-on-pagure/* - cp -r docs/_build/html/* docs-on-pagure/ - cd docs-on-pagure - git add -A . - if [[ "$(git diff --cached --numstat | wc -l)" -eq 0 ]] ; then - exit 0 # No changes, nothing to commit - fi - git commit -m 'Automatic commit of docs built by Jenkins job ${env.JOB_NAME} #${env.BUILD_NUMBER}' - git push origin master - ''' - } - } - } stage('Build SRPM') { sh './rpmbuild.sh -bs' archiveArtifacts artifacts: 'rpmbuild-output/**' @@ -249,33 +226,6 @@ node('fedora') { } } } -node('docker') { - checkout scm - - if (scmVars.GIT_BRANCH == 'origin/master') { - stage('Tag "latest".') { - unarchive mapping: ['appversion': 'appversion'] - def appversion = readFile('appversion').trim() - docker.withRegistry( - 'https://docker-registry.engineering.redhat.com/', - 'docker-registry-factory2-builder-sa-credentials') { - def image = docker.image("factory2/waiverdb:internal-${appversion}") - /* Pushes to the internal registry can sometimes randomly fail - * with "unknown blob" due to a known issue with the registry - * storage configuration. So we retry up to 3 times. */ - retry(3) { - image.push('latest') - } - } - docker.withRegistry( - 'https://quay.io/', - 'quay-io-factory2-builder-sa-credentials') { - def image = docker.image("factory2/waiverdb:${appversion}") - image.push('latest') - } - } - } -} } // end timestamps } catch (e) { // since the result isn't set until after the pipeline script runs, we must set it here if it fails @@ -335,4 +285,4 @@ node('docker') { ] } } -} \ No newline at end of file +}