Skip to content

Commit 13a1569

Browse files
committed
Bump parent image to debian:bullseye-slim
Upgrade to debian:bullseye-slim (Debian 11) as parent Docker image with Python 3.9.2 and some packages from bullseye-backports. Refresh Python libraries from Debian packages: - python3-cffi: 1.14.3 → 1.14.5 - python3-chardet: 3.0.4 → 4.0.0 - python3-elasticsearch: 7.16.1 → 7.17.5 - python3-gdal: 3.1.3 → 3.2.2 - python3-numpy: 1.19.2 → 1.19.5 - python3-pandas 1.0.5 → 1.1.5 - python3-psycopg2: 2.8.5 → 2.9.3 (from PGDG) - python3-pytz: 2020.1 → 2021.1 - python3-requests: 2.23.0 → 2.25.1 - python3-six: 1.15.0 → 1.16.0 - python3-sqlalchemy: 1.3.19 → 1.3.22 Update README.md and docker-publish.yml accordingly. Fixes #3
1 parent 43a8c4c commit 13a1569

File tree

4 files changed

+51
-48
lines changed

4 files changed

+51
-48
lines changed

.github/workflows/docker-publish.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ on:
1111
#schedule:
1212
# - cron: '34 11 * * *'
1313
branches:
14-
- master # Currently tracking debian-sid-20201012
14+
- master # Currently debian-bullseye
1515
- debian-sid-20201012 # Python 3.8.6 (Debian during bullseye development cycle)
1616
- debian-bullseye # Python 3.9.2 (Debian 11)
1717
- debian-bookworm # Python 3.10.6 (Debian 12 in development)

Dockerfile

+27-30
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# =================================================================
22
#
3-
# Author: Joost van Ulden <[email protected]>
3+
# Authors: Joost van Ulden <[email protected]>
4+
# Anthony Fok <[email protected]>
45
#
56
# Copyright (c) 2020-2022 Government of Canada
67
#
@@ -27,39 +28,51 @@
2728
#
2829
# =================================================================
2930

30-
FROM debian:sid-20201012-slim
31+
FROM debian:bullseye-slim
3132

3233
LABEL org.opencontainers.image.authors="Joost van Ulden <[email protected]>, Anthony Fok <[email protected]>"
3334
LABEL org.opencontainers.image.source="https://github.com/opendrr/python-env"
34-
LABEL org.opencontainers.image.version="1.2.4"
35+
LABEL org.opencontainers.image.version="1.3.0"
3536
LABEL org.opencontainers.image.vendor="Government of Canada"
3637
LABEL org.opencontainers.image.licenses="MIT"
3738

39+
# To use Debian Snapshot, prepend the following commands:
40+
# echo 'Acquire::Check-Valid-Until "false";' > /etc/apt/apt.conf.d/docker-snapshot.conf
41+
# sed -i '/snapshot.debian.org/s/^# //; /deb.debian.org/s/^/# /' /etc/apt/sources.list
42+
3843
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
39-
RUN echo 'Acquire::Check-Valid-Until "false";' > /etc/apt/apt.conf.d/docker-snapshot.conf \
40-
&& sed -i '/snapshot.debian.org/s/^# //; /deb.debian.org/s/^/# /' /etc/apt/sources.list \
41-
&& echo 'deb http://deb.debian.org/debian bullseye main' >> /etc/apt/sources.list \
42-
&& echo 'deb http://deb.debian.org/debian bullseye-backports main' >> /etc/apt/sources.list \
43-
&& printf 'Package: *\n\
44-
Pin: release n=bullseye\n\
45-
Pin-Priority: 50' > /etc/apt/preferences.d/git-in-bullseye \
46-
&& cat /etc/apt/preferences.d/git-in-bullseye \
44+
RUN echo 'deb http://deb.debian.org/debian bullseye-backports main' >> /etc/apt/sources.list \
4745
&& apt-get update \
4846
&& apt-get install -y --no-install-recommends \
49-
eatmydata \
50-
&& eatmydata apt-get install -y --no-install-recommends \
5147
ca-certificates \
5248
curl \
49+
eatmydata \
50+
gpg \
51+
&& curl https://www.postgresql.org/media/keys/ACCC4CF8.asc | gpg --dearmor \
52+
| tee /etc/apt/trusted.gpg.d/apt.postgresql.org.gpg >/dev/null \
53+
&& echo 'deb http://apt.postgresql.org/pub/repos/apt/ bullseye-pgdg main 14' \
54+
> /etc/apt/sources.list.d/pgdg.list \
55+
&& curl -fsSL --create-dirs --output /usr/share/keyrings/githubcli-archive-keyring.gpg \
56+
https://cli.github.com/packages/githubcli-archive-keyring.gpg \
57+
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" \
58+
> /etc/apt/sources.list.d/github-cli.list \
59+
&& eatmydata apt-get update \
60+
&& eatmydata apt-get install -t bullseye-backports -y --no-install-recommends \
61+
7zip \
5362
dos2unix \
5463
gdal-bin \
55-
gpg \
64+
git \
65+
git-lfs \
66+
gh \
5667
jq \
5768
moreutils \
5869
nano \
5970
neovim \
71+
postgresql-client \
6072
procps \
6173
pv \
6274
pypy3 \
75+
python3-elasticsearch \
6376
python3-numpy \
6477
python3-pandas \
6578
python3-psycopg2 \
@@ -69,22 +82,6 @@ Pin-Priority: 50' > /etc/apt/preferences.d/git-in-bullseye \
6982
python3-pip \
7083
time \
7184
xz-utils \
72-
&& eatmydata apt-get install -y --no-install-recommends -t bullseye-backports \
73-
7zip \
74-
git \
75-
git-lfs \
76-
&& curl https://www.postgresql.org/media/keys/ACCC4CF8.asc | gpg --dearmor \
77-
| tee /etc/apt/trusted.gpg.d/apt.postgresql.org.gpg >/dev/null \
78-
&& echo 'deb http://apt.postgresql.org/pub/repos/apt/ bullseye-pgdg main 14' \
79-
> /etc/apt/sources.list.d/pgdg.list \
80-
&& curl -fsSL --create-dirs --output /usr/share/keyrings/githubcli-archive-keyring.gpg \
81-
https://cli.github.com/packages/githubcli-archive-keyring.gpg \
82-
&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" \
83-
> /etc/apt/sources.list.d/github-cli.list \
84-
&& eatmydata apt-get update \
85-
&& eatmydata apt-get install -y --no-install-recommends \
86-
gh \
87-
postgresql-client \
8885
&& rm -rf /var/lib/apt/lists/*
8986

9087
COPY requirements.txt /tmp

README.md

+12-6
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,25 @@ tailored for the OpenDRR/opendrr-api stack build process.
99

1010
Existing versions/branches:
1111

12-
* v1.0: Python 3.8.5, based on debian:sid-20200720-slim (between Debian 10 and Debian 11, `opendrr/python-env:1.0`)
13-
* v1.0.3: Python 3.8.5, based on debian:sid-20200720-slim (between Debian 10 and Debian 11, `ghcr.io/opendrr/python-env:1.0.3`)
14-
* v1.1.0: Python 3.8.6, based on debian:sid-20201012-slim (between Debian 10 and Debian 11)
1512
* v1.2.x, `latest` (stable): Python 3.8.6, Elasticsearch 7.16, based on debian:sid-20201012-slim, with the use of requirements.txt restored
16-
* `debian-sid-20201012` branch, also the `master` branch currently
13+
* `debian-sid-20201012` branch
14+
* Image: `ghcr.io/opendrr/python-env:1.2.4`
15+
1716
* v1.3.x (dev): Python 3.9.2, Elasticsearch 7.17, based on debian:bullseye-slim (Debian 11, released August 2022)
18-
* `debian-bullseye` branch
17+
* `debian-bullseye` branch, also the current `master` branch
18+
* Image: `ghcr.io/opendrr/python-env:1.3.0`, `ghcr.io/opendrr/python-env:debian-bullseye`, `ghcr.io/opendrr/python-env:edge`
1919

20-
Planned branches/versions:
20+
Planned future branch/versions:
2121

2222
* v1.4.x (dev): Python 3.10.x, Elasticsearch 8.x, based on debian:bookworm-slim (Debian 12, expected to be released in mid-2023)
2323
* `debian-bookworm` branch
2424

25+
Previous versions:
26+
27+
* v1.1.0: Python 3.8.6, based on debian:sid-20201012-slim (between Debian 10 and Debian 11)
28+
* v1.0.3: Python 3.8.5, based on debian:sid-20200720-slim (between Debian 10 and Debian 11, `ghcr.io/opendrr/python-env:1.0.3`)
29+
* v1.0: Python 3.8.5, based on debian:sid-20200720-slim (between Debian 10 and Debian 11, `opendrr/python-env:1.0`)
30+
2531
## Updating ghcr.io/opendrr/python-env:edge (for testing)
2632

2733
1. Push your latest commits to the `master` branch.

requirements.txt

+11-11
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
certifi==2020.6.20
2-
cffi==1.14.3
3-
chardet==3.0.4
4-
elasticsearch==7.16.1
5-
GDAL==3.1.3
2+
cffi==1.14.5
3+
chardet==4.0.0
4+
elasticsearch==7.17.5
5+
GDAL==3.2.2
66
idna==2.10
7-
numpy==1.19.2
8-
pandas==1.0.5
7+
numpy==1.19.5
8+
pandas==1.1.5
99
ply==3.11
10-
psycopg2==2.8.5
10+
psycopg2==2.9.3
1111
psycopg2cffi==2.8.1
1212
pycparser==2.20
1313
python-dateutil==2.8.1
14-
pytz==2020.1
15-
requests==2.23.0
16-
six==1.15.0
17-
SQLAlchemy==1.3.19
14+
pytz==2021.1
15+
requests==2.25.1
16+
six==1.16.0
17+
SQLAlchemy==1.3.22
1818
urllib3==1.26.12

0 commit comments

Comments
 (0)