36 lines
923 B
Plaintext
36 lines
923 B
Plaintext
pipeline {
|
|
agent none
|
|
stages {
|
|
stage('copy files') {
|
|
agent any
|
|
steps {
|
|
sh '''
|
|
cp ./lab3/script.sh .
|
|
cp ./lab3/python_script.py .
|
|
cp ./lab3/Dockerfile .
|
|
cp ./lab3/requirements.txt .
|
|
'''
|
|
}
|
|
}
|
|
stage('docker') {
|
|
agent {
|
|
dockerfile true
|
|
}
|
|
stages {
|
|
stage('script') {
|
|
steps {
|
|
sh '''
|
|
chmod +x script.sh
|
|
./script.sh >> stats.txt'''
|
|
}
|
|
}
|
|
stage('archive artifact') {
|
|
steps {
|
|
archiveArtifacts 'stats.txt'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|