Use pipenv and pyenv for CI/CD pipeline.

This commit is contained in:
Sumner Evans
2019-11-24 01:44:08 +00:00
parent 9da03461b9
commit 0dbdd9ead8
6 changed files with 65 additions and 12 deletions

View File

@@ -3,4 +3,19 @@ FROM ubuntu:18.04
MAINTAINER sumner "https://gitlab.com/sumner"
RUN apt update && \
apt install -y python3-pip libcairo2-dev pkg-config libgtk-3-dev libmpv-dev libglib2.0-dev gir1.2-notify-0.7
export TZ=America/Denver DEBIAN_FRONTEND=noninteractive && \
apt install -y \
python3-pip libcairo2-dev pkg-config libgtk-3-dev libmpv-dev \
libglib2.0-dev gir1.2-notify-0.7 make build-essential libssl-dev \
zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm \
libncurses5-dev libncursesw5-dev xz-utils tk-dev libffi-dev \
liblzma-dev python-openssl git libgirepository1.0-dev
RUN cd /usr/local/src && \
curl -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer | bash
RUN pip3 install pipenv
# Install the correct Python version with pyenv
COPY install-python.sh /tmp/install-python.sh
RUN /tmp/install-python.sh

View File

@@ -0,0 +1,6 @@
#! /bin/sh
export PYENV_ROOT="${HOME}/.pyenv"
export PATH="${PYENV_ROOT}/bin:$PATH"
eval "$(pyenv init -)"
pyenv install 3.8.0