Skip to content

Commit

Permalink
attempt at full command; work on #158
Browse files Browse the repository at this point in the history
  • Loading branch information
kltm committed Jan 29, 2020
1 parent 7b26df7 commit ab123a6
Showing 1 changed file with 35 additions and 40 deletions.
75 changes: 35 additions & 40 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ pipeline {
git 'https://github.com/geneontology/go-ontology.git'

// Default namespace.
sh 'env'
sh 'env'

dir('./src/ontology') {
retry(3){
Expand All @@ -376,54 +376,49 @@ pipeline {
if( found_core_dump_p ){
error 'ROBOT core dump detected--bailing out.'
}
}
}
}

// Attempt to use pathways2GO release.

// TODO: here.
}
}
}
stage('Make Noctua GPAD') {
steps {
// May be parallelized in the future, but may need to
// serve as input into into mega step.
script {
stage('Produce ontology') {
// agent {
// docker {
// image 'obolibrary/odkfull:v1.1.7'
// // Reset Jenkins Docker agent default to original
// // root.
// args '-u root:root'
// }
// }

dir('./noctua-models') {
git url: 'https://github.com/geneontology/noctua-models.git'
// Attempt to use pathways2GO release.
// Create a relative working directory and setup our
// data environment.
dir('./pathways2GO') {
git 'https://github.com/geneontology/pathways2GO.git'

// Make all software products available in bin/
// (and lib/).
sh 'mkdir -p bin/'
sh 'mkdir -p lib/'
withCredentials([file(credentialsId: 'skyhook-private-key', variable: 'SKYHOOK_IDENTITY')]) {
sh 'rsync -avz -e "ssh -o StrictHostKeyChecking=no -o IdentitiesOnly=true -o IdentityFile=$SKYHOOK_IDENTITY" [email protected]:/home/skyhook/$BRANCH_NAME/bin/* ./bin/'
// WARNING/BUG: needed for blazegraph-runner
// to run at this point.
sh 'rsync -avz -e "ssh -o StrictHostKeyChecking=no -o IdentitiesOnly=true -o IdentityFile=$SKYHOOK_IDENTITY" [email protected]:/home/skyhook/$BRANCH_NAME/lib/* ./lib/'
}
sh 'chmod +x bin/*'
// Default namespace.
sh 'env'

// Compile models.
sh 'mkdir -p legacy/gpad'
withEnv(['MINERVA_CLI_MEMORY=128G']){
// "Import" models.
sh './bin/minerva-cli.sh --import-owl-models -f models -j blazegraph.jnl'
// Convert GO-CAM to GPAD.
sh './bin/minerva-cli.sh --lego-to-gpad-sparql --ontology $MINERVA_INPUT_ONTOLOGIES -i blazegraph.jnl --gpad-output legacy/gpad'
}
retry(3){

// Collation.
sh 'perl ./util/collate-gpads.pl legacy/gpad/*.gpad'
// Get jar.
sh 'wget -N https://github.com/geneontology/pathways2GO/releases/download/v0.1.0/biopax2go.jar'

// Rename, compress, and move to skyhook.
sh 'mcp "legacy/*.gpad" "legacy/noctua_#1.gpad"'
sh 'gzip -vk legacy/noctua_*.gpad'
withCredentials([file(credentialsId: 'skyhook-private-key', variable: 'SKYHOOK_IDENTITY')]) {
sh 'scp -o StrictHostKeyChecking=no -o IdentitiesOnly=true -o IdentityFile=$SKYHOOK_IDENTITY legacy/noctua_*.gpad.gz [email protected]:/home/skyhook/$BRANCH_NAME/products/annotations/'
}
// Biopax files needed
sh 'wget -N https://reactome.org/download/current/biopax.zip'
sh 'gunzip biopax.zip'

// The actual command.
sh 'java -jar biopax2go.jar -b Homo-sapiens.owl -reacto ./REACTO -c catalog-v001-for-noctua.xml -lego http://skyhook.berkeleybop.org/issue-158-reactome-ontology/ontology/extensions/go-lego.owl'

// Fake Catalog.
sh 'touch catalog-v001-for-noctua.xml'

// Make sure that we copy any files there,
// including the core dump of produced.
withCredentials([file(credentialsId: 'skyhook-private-key', variable: 'SKYHOOK_IDENTITY')]) {
sh 'scp -o StrictHostKeyChecking=no -o IdentitiesOnly=true -o IdentityFile=$SKYHOOK_IDENTITY -r ./REACTO/* [email protected]:/home/skyhook/$BRANCH_NAME/ontology/extensions/'
}
}
}
Expand Down

0 comments on commit ab123a6

Please sign in to comment.