From e586b2611091ec1c5d55a58774c8cc15da2e61f2 Mon Sep 17 00:00:00 2001 From: YuviPanda Date: Tue, 13 Jun 2023 13:00:54 +0530 Subject: [PATCH 1/2] Upgrade base image to Ubuntu 22.04 18.04 was EOL May 2023, with only paid support now available (https://ubuntu.com/blog/18-04-end-of-standard-support). Let's bump the default base image to 22.04. This might break some repos that have apt.txt based packages, but I don't really think there's a way around that. If specific package pinning is needed, users unfortunately need to use a Dockerfile. Ref https://github.com/jupyterhub/repo2docker/issues/1258 --- docs/source/design.md | 2 +- docs/source/howto/base_image.md | 4 ++-- repo2docker/app.py | 2 +- repo2docker/buildpacks/r.py | 2 +- tests/conftest.py | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/source/design.md b/docs/source/design.md index 7f6536941..6077621d7 100644 --- a/docs/source/design.md +++ b/docs/source/design.md @@ -49,7 +49,7 @@ Many ingredients go into making an image from a repository: `repo2docker` controls the first two, the user controls the third one. The current policy for the version of the base image is that we will use the current LTS -version Bionic Beaver (18.04) for the foreseeable future. +version Jammy Jellyfish (22.04) for the foreseeable future. The version of `repo2docker` used to build an image can influence which packages are installed by default and which features are supported during the build diff --git a/docs/source/howto/base_image.md b/docs/source/howto/base_image.md index 6fa8f5173..e9ab45ea9 100644 --- a/docs/source/howto/base_image.md +++ b/docs/source/howto/base_image.md @@ -7,7 +7,7 @@ To do so, use the `base_image` traitlet when invoking `repo2docker`. Note that this is not configurable by individual repositories, it is configured when you invoke the `repo2docker` command. ```{note} -By default repo2docker builds on top of the `buildpack-deps:bionic` base image, an Ubuntu-based image. +By default repo2docker builds on top of the `buildpack-deps:jammy` base image, an Ubuntu-based image. ``` ## Requirements for your base image @@ -26,7 +26,7 @@ Changing the base image may have an impact on the reproducibility of repositorie There are **no guarantees that repositories will behave the same way as other repo2docker builds if you change the base image**. For example these are two scenarios that would make your repositories non-reproducible: -- **Your base image is different from `Ubuntu:bionic`.** +- **Your base image is different from `Ubuntu:jammy`.** If you change the base image in a way that is different from repo2docker's default (the Ubuntu `bionic` image), then repositories that **you** build with repo2docker may be significantly different from those that **other** instances of repo2docker build (e.g., those from [`mybinder.org`](https://mybinder.org)). - **Your base image changes over time.** If you choose a base image that changes its composition over time (e.g., an image provided by some other community), then it may cause repositories build with your base image to change in unpredictable ways. diff --git a/repo2docker/app.py b/repo2docker/app.py index 6a574a8c0..63643da23 100755 --- a/repo2docker/app.py +++ b/repo2docker/app.py @@ -448,7 +448,7 @@ def _dry_run_changed(self, change): ) base_image = Unicode( - "docker.io/library/buildpack-deps:bionic", + "docker.io/library/buildpack-deps:jammy", config=True, help=""" Base image to use when building docker images. diff --git a/repo2docker/buildpacks/r.py b/repo2docker/buildpacks/r.py index 7dd724e04..742638840 100644 --- a/repo2docker/buildpacks/r.py +++ b/repo2docker/buildpacks/r.py @@ -217,7 +217,7 @@ def get_rspm_snapshot_url(self, snapshot_date, max_days_prior=7): ), }, ).json() - # Construct a snapshot URL that will give us binary packages for Ubuntu Bionic (18.04) + # Construct a snapshot URL that will give us binary packages for appropriate ubuntu version if "upsi" in snapshots: return ( # Env variables here are expanded by envsubst in the Dockerfile, after sourcing diff --git a/tests/conftest.py b/tests/conftest.py index a09ef0420..87cccb8bd 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -105,7 +105,7 @@ def base_image(): """ Base ubuntu image to use when testing specific BuildPacks """ - return "buildpack-deps:bionic" + return "buildpack-deps:jammy" def _add_content_to_git(repo_dir): From c53971b1b53693cb3b106ac24149129e96634cb5 Mon Sep 17 00:00:00 2001 From: Erik Sundell Date: Tue, 8 Aug 2023 12:24:41 +0200 Subject: [PATCH 2/2] docs: fix outdated reference to ubuntu:bionic --- docs/source/howto/base_image.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/howto/base_image.md b/docs/source/howto/base_image.md index e9ab45ea9..823a05491 100644 --- a/docs/source/howto/base_image.md +++ b/docs/source/howto/base_image.md @@ -27,7 +27,7 @@ There are **no guarantees that repositories will behave the same way as other re For example these are two scenarios that would make your repositories non-reproducible: - **Your base image is different from `Ubuntu:jammy`.** - If you change the base image in a way that is different from repo2docker's default (the Ubuntu `bionic` image), then repositories that **you** build with repo2docker may be significantly different from those that **other** instances of repo2docker build (e.g., those from [`mybinder.org`](https://mybinder.org)). + If you change the base image in a way that is different from repo2docker's default (the Ubuntu `jammy` image), then repositories that **you** build with repo2docker may be significantly different from those that **other** instances of repo2docker build (e.g., those from [`mybinder.org`](https://mybinder.org)). - **Your base image changes over time.** If you choose a base image that changes its composition over time (e.g., an image provided by some other community), then it may cause repositories build with your base image to change in unpredictable ways. We recommend choosing a base image that you know to be stable and trustworthy.