ium_470607/lab2/Jenkinsfile_create_dataset

62 lines
1.8 KiB
Plaintext
Raw Normal View History

2021-03-27 16:54:42 +01:00
pipeline {
2021-04-11 11:04:32 +02:00
agent none
/* parameters {
2021-03-28 19:38:13 +02:00
string(defaultValue: '6000',
2021-03-28 18:40:49 +02:00
description: 'numbers of data entries to keep in train.csv',
name: 'CUTOFF',
trim: true)
}
2021-04-11 11:04:32 +02:00
*/
2021-03-27 16:54:42 +01:00
stages {
2021-04-11 11:04:32 +02:00
stage('copy files') {
agent any
steps {
sh '''
cp ./lab1/script.sh .
cp ./lab1/python_script.py .
cp ./lab3/Dockerfile .
cp ./lab3/requirements.txt .
'''
}
}
/* stage('sh: Shell Script') {
2021-03-27 16:54:42 +01:00
steps {
2021-03-28 13:29:04 +02:00
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}",
"KAGGLE_KEY=${params.KAGGLE_KEY}" ]) {
2021-04-11 11:04:32 +02:00
sh ''' chmod +x ./lab2/script-zadanie-2-4.sh
./lab2/script-zadanie-2-4.sh
chmod +x ./lab2/script-zadanie-2-4-cutoff.sh'''
2021-04-02 22:14:19 +02:00
sh "./lab2/script-zadanie-2-4-cutoff.sh ${params.CUTOFF}"
2021-03-28 13:29:04 +02:00
}
2021-03-28 17:29:26 +02:00
}
}
2021-04-11 11:04:32 +02:00
*/
stage('docker') {
agent {
dockerfile true
}
stages {
stage('test') {
steps {
sh 'cat /etc/issue'
}
}
stage('actual') {
steps {
2021-04-11 11:14:06 +02:00
sh '''
chmod +x script.sh
./script.sh'''
2021-04-11 11:04:32 +02:00
}
}
stage('archive artifacts') {
steps {
archiveArtifacts 'train.csv'
archiveArtifacts 'test.csv'
archiveArtifacts 'valid.csv'
}
}
2021-03-27 16:54:42 +01:00
}
}
}
}