2022-03-31 20:15:29 +02:00
|
|
|
# Latest Ubuntu as starter
|
2022-03-28 11:23:11 +02:00
|
|
|
FROM ubuntu:latest
|
|
|
|
|
2022-03-31 20:15:29 +02:00
|
|
|
# Install required dependencies
|
|
|
|
RUN apt update
|
|
|
|
RUN export PATH=”$PATH:/usr/local/bin/python”
|
|
|
|
RUN apt install python3-pip -y
|
|
|
|
RUN apt install unzip -y
|
|
|
|
RUN pip install kaggle
|
|
|
|
RUN pip install pandas
|
|
|
|
RUN pip install scikit-learn
|
|
|
|
RUN pip install matplotlib
|
|
|
|
RUN mkdir ~/.kaggle/
|
|
|
|
RUN echo '{"username":"wirus006","key":"c3323e37d3f91a0914d0172ef3c7c30c"}' > ~/.kaggle/kaggle.json
|
2022-03-28 11:23:11 +02:00
|
|
|
|
2022-03-31 20:15:29 +02:00
|
|
|
# Create app directory in image
|
2022-03-28 11:23:11 +02:00
|
|
|
WORKDIR /app
|
|
|
|
|
2022-03-31 20:15:29 +02:00
|
|
|
# Copy init dataset script to /app directory in image
|
|
|
|
COPY ./init.py ./
|
2022-03-28 11:23:11 +02:00
|
|
|
|
2022-03-31 20:15:29 +02:00
|
|
|
# Download kaggle dataset
|
|
|
|
RUN kaggle datasets download -d hakeem/atp-and-wta-tennis-data
|
|
|
|
RUN unzip -o atp-and-wta-tennis-data.zip
|
|
|
|
|
|
|
|
# Script executed after docker run
|
|
|
|
CMD python3 ./init.py
|