openpilot0/Dockerfile.openpilot_base

34 lines
1.1 KiB
Docker
Raw Normal View History

FROM ubuntu:20.04
ENV PYTHONUNBUFFERED 1
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && \
apt-get install -y --no-install-recommends sudo tzdata locales ssh && \
rm -rf /var/lib/apt/lists/*
RUN sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && locale-gen
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8
Pipenv -> poetry (#24858) * Try poetry * Remove casadi for now * Update docker * Copy pipfiles * add casadi back * Too many slashes * New poetry api * Install system * Try again * No more pipenv * new dependencies * updates * poetry 1.2.1, install dev dependencies * keep install pipenv for xx for now? * add pre-commit checks for poetry * poetry lock is too slow * update pip * migrate to poetry groups * update lockfile * don't need to specify dev group unless it is made optional * always install poetry * set POETRY_VIRTUALENVS_CREATE instead, and use pipenv for xx * use env for docs docker image * alphabetical * poetry 1.2.2 * add dev dependencies for typing added in aacf6ae3 * remove constraint * fix PIPENV_SYSTEM * remove constraint * don't need this here * bump * bump pipenv adds support for installing local pyprojects (can add openpilot as dependency of xx) * README improvements * probably not necessary * bump pip * maybe not necessary? * revert * don't install openpilot itself into the virtual env * remove PySide2 and shiboken2 reverts 3e41c775cbf670740ac648a8614d2d6b433312fe * remove Pipenv, add xx dependencies, sync system python * add pipenv as xx dep * semver package constraints, use old lockfile versions * fix casadi * remove whitespace Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com> * disable poetry cache * cleanup * prefer config file Co-authored-by: Cameron Clough <cameronjclough@gmail.com> Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com> old-commit-hash: a98d105cb95a445f5ec69e783585c56604b09449
2022-10-22 07:23:56 +08:00
ENV POETRY_VIRTUALENVS_CREATE=false
ENV PYENV_VERSION=3.11.4
ENV PYENV_ROOT="/root/.pyenv"
ENV PATH="$PYENV_ROOT/bin:$PYENV_ROOT/shims:$PATH"
COPY pyproject.toml poetry.lock .python-version /tmp/
COPY tools/ubuntu_setup.sh tools/install_ubuntu_dependencies.sh tools/install_python_dependencies.sh /tmp/tools/
RUN cd /tmp && \
tools/ubuntu_setup.sh && \
rm -rf /var/lib/apt/lists/* && \
rm -rf /tmp/* && \
rm -rf /root/.cache && \
Pipenv -> poetry (#24858) * Try poetry * Remove casadi for now * Update docker * Copy pipfiles * add casadi back * Too many slashes * New poetry api * Install system * Try again * No more pipenv * new dependencies * updates * poetry 1.2.1, install dev dependencies * keep install pipenv for xx for now? * add pre-commit checks for poetry * poetry lock is too slow * update pip * migrate to poetry groups * update lockfile * don't need to specify dev group unless it is made optional * always install poetry * set POETRY_VIRTUALENVS_CREATE instead, and use pipenv for xx * use env for docs docker image * alphabetical * poetry 1.2.2 * add dev dependencies for typing added in aacf6ae3 * remove constraint * fix PIPENV_SYSTEM * remove constraint * don't need this here * bump * bump pipenv adds support for installing local pyprojects (can add openpilot as dependency of xx) * README improvements * probably not necessary * bump pip * maybe not necessary? * revert * don't install openpilot itself into the virtual env * remove PySide2 and shiboken2 reverts 3e41c775cbf670740ac648a8614d2d6b433312fe * remove Pipenv, add xx dependencies, sync system python * add pipenv as xx dep * semver package constraints, use old lockfile versions * fix casadi * remove whitespace Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com> * disable poetry cache * cleanup * prefer config file Co-authored-by: Cameron Clough <cameronjclough@gmail.com> Co-authored-by: Adeeb Shihadeh <adeebshihadeh@gmail.com> old-commit-hash: a98d105cb95a445f5ec69e783585c56604b09449
2022-10-22 07:23:56 +08:00
pip uninstall -y poetry && \
# remove unused architectures from gcc for panda
cd /usr/lib/gcc/arm-none-eabi/9.2.1 && \
rm -rf arm/ && \
rm -rf thumb/nofp thumb/v6* thumb/v8* thumb/v7+fp thumb/v7-r+fp.sp
RUN sudo git config --global --add safe.directory /tmp/openpilot