28 lines
691 B
Groovy
28 lines
691 B
Groovy
pipeline {
|
|
agent any
|
|
|
|
stages {
|
|
stage('Checkout') {
|
|
steps {
|
|
git branch: 'master', url: 'https://git.wmi.amu.edu.pl/s487178/ium_s487178.git'
|
|
}
|
|
}
|
|
|
|
stage('Build Docker image') {
|
|
steps {
|
|
sh 'docker build -t ium_s487178 -f dockerfile3 .'
|
|
}
|
|
}
|
|
|
|
stage('Run Python script') {
|
|
steps {
|
|
script {
|
|
docker.image('ium_s487178').inside {
|
|
sh 'python my_script.py > output.txt'
|
|
}
|
|
archiveArtifacts 'output.txt'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} |