From 13c94088b44d7ab6d4d029f56a208d3ba4285eb9 Mon Sep 17 00:00:00 2001 From: Michael Halstead Date: Fri, 16 Dec 2022 08:42:54 -0800 Subject: [PATCH] Dockerfile: switch to ubuntu:jammy for >python3.8 ubuntu:jammy provides python 3.10.6 which supports current bitbake. Dropped unneeded python2 packages. Moved locale generation high to reduce error messages during image building. Signed-off-by: Michael Halstead Signed-off-by: Tim Orling --- Dockerfile | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/Dockerfile b/Dockerfile index a6c7ad2..d8c38e1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # See README for how to use this. -FROM debian:buster +FROM ubuntu:jammy LABEL maintainer="Michael Halstead " ENV PYTHONUNBUFFERED=1 \ @@ -17,30 +17,29 @@ ENV PYTHONUNBUFFERED=1 \ COPY requirements.txt / RUN DEBIAN_FRONTEND=noninteractive apt-get update \ + && apt-get install -y locales \ + && echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen \ + && locale-gen en_US.UTF-8 \ + && update-locale \ && apt-get install -y --no-install-recommends \ autoconf \ g++ \ gcc \ make \ - python-pip \ - python-mysqldb \ - python-dev \ - python-pil \ - python-wheel \ + python2 \ python3-pip \ python3-mysqldb \ python3-dev \ python3-pil \ python3-wheel \ - libz-dev \ + zlib1g-dev \ libfreetype6-dev \ libjpeg-dev \ - libmariadbclient-dev \ - locales \ + libmariadb-dev-compat \ netcat-openbsd \ curl \ wget \ - git-core \ + git \ vim \ rpm2cpio \ rpm \ @@ -51,7 +50,7 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get update \ && pip3 install gunicorn \ && pip3 install setuptools \ && pip3 install -r /requirements.txt \ - && apt-get purge -y autoconf g++ make python3-dev libjpeg-dev libmariadbclient-dev \ + && apt-get purge -y autoconf g++ make python3-dev libjpeg-dev \ && apt-get autoremove -y \ && rm -rf /var/lib/apt/lists/* \ && apt-get clean