Attempt 4

This commit is contained in:
Paweł Skórzewski 2024-04-10 09:47:11 +02:00
parent 69fea92fce
commit d9e85025e2
2 changed files with 1 additions and 23 deletions

View File

@ -1,18 +1,10 @@
# Nasz obraz będzie dziedziczył z obrazu Ubuntu w wersji latest
FROM ubuntu:latest
FROM python:3.10
# Instalujemy niezbędne zależności. Zwróć uwagę na flagę "-y" (assume yes)
RUN apt update && apt install -y python3-pip
RUN pip3 install datasets kaggle
RUN pip3 list
# Stwórzmy w kontenerze (jeśli nie istnieje) katalog /app i przejdźmy do niego (wszystkie kolejne polecenia RUN, CMD, ENTRYPOINT, COPY i ADD będą w nim wykonywane)
WORKDIR /app
# Skopiujmy nasz skrypt do katalogu /app w kontenerze
COPY ./create-dataset.py ./
# # Domyślne polecenie, które zostanie uruchomione w kontenerze po jego starcie
# CMD python3 create-dataset.py

View File

@ -24,11 +24,6 @@ pipeline {
}
stages {
stage('Test') {
steps {
sh 'pip3 list'
}
}
stage('Checkout') {
steps {
checkout scmGit(
@ -39,18 +34,9 @@ pipeline {
}
stage('Kaggle') {
steps {
sh 'pip list'
sh 'pip3 list'
sh 'pip3 --version'
sh 'python3 --version'
script {
withEnv(["KAGGLE_USERNAME=${params.KAGGLE_USERNAME}", "KAGGLE_KEY=${params.KAGGLE_KEY}" ]) {
sh 'pip list'
sh 'pip3 list'
sh 'pip3 --version'
sh 'python3 --version'
sh 'echo KAGGLE_USERNAME: $KAGGLE_USERNAME'
sh 'mkdir ~/.kaggle'
sh 'kaggle datasets list'
}
}