ium_444417/Jenkinsfile3
s444417 68e41a262b
Some checks failed
s444417-training/pipeline/head There was a failure building this commit
conda
2022-05-21 13:27:43 +02:00

60 lines
1.6 KiB
Plaintext

pipeline {
agent {
dockerfile {
args '-v /mlruns:/mlruns'
}
}
parameters{
string(
defaultValue: '5',
description: 'Epoch number',
name: 'EPOCH_NUMBER'
)
}
stages {
stage('conda') {
steps {
sh 'conda env create -f environment.yml'
sh 'conda activate myenv'
}
}
stage('Copy') {
steps {
copyArtifacts projectName: 's444417-create-dataset'
sh 'ls -la'
sh 'echo $EPOCH_NUMBER'
sh 'python3 ./lab8/trainScript.py'
}
}
stage('Archive') {
steps {
dir('saved_model') {
archiveArtifacts artifacts: '**/**'
}
dir('my_runs') {
archiveArtifacts artifacts: '**/**'
}
}
}
stage('Starting eval job') {
steps {
build job: 's444417-evaluation/master', wait: false
}
}
stage('Archive mlflow') {
steps {
sh 'cd ./lab8'
sh 'tar -czf mlruns.tar.gz mlruns/'
archiveArtifacts 'mlruns.tar.gz'
}
}
}
options {
copyArtifactPermission('s444417-evaluation');
}
post {
always {
emailext body: "${currentBuild.currentResult}", subject: 's444417-testing build status', to: 'e19191c5.uam.onmicrosoft.com@emea.teams.ms'
}
}
}