From 47a752d889c97fcccb1c37148af0765719478d95 Mon Sep 17 00:00:00 2001 From: Markus Kahl Date: Fri, 26 Feb 2021 13:10:51 +0000 Subject: [PATCH] make sure to use latest patch level of ruby base image (#9052) * make sure to use latest patch level of ruby base image * how to handle outdated images --- docker/ci/Dockerfile | 2 +- docker/dev/backend/Dockerfile | 2 +- docker/prod/Dockerfile | 2 +- .../development-environment-docker/README.md | 17 +++++++++++++++++ 4 files changed, 20 insertions(+), 3 deletions(-) diff --git a/docker/ci/Dockerfile b/docker/ci/Dockerfile index 6dac1eeb46..415904ec95 100644 --- a/docker/ci/Dockerfile +++ b/docker/ci/Dockerfile @@ -1,4 +1,4 @@ -FROM ruby:2.7.2-buster +FROM ruby:2.7-buster MAINTAINER operations@openproject.com ENV USER=dev diff --git a/docker/dev/backend/Dockerfile b/docker/dev/backend/Dockerfile index 0061587acb..10795c9fdb 100644 --- a/docker/dev/backend/Dockerfile +++ b/docker/dev/backend/Dockerfile @@ -1,4 +1,4 @@ -FROM ruby:2.7.2-buster as develop +FROM ruby:2.7-buster as develop MAINTAINER operations@openproject.com ARG DEV_UID=1000 diff --git a/docker/prod/Dockerfile b/docker/prod/Dockerfile index c438633667..96cca16bf1 100644 --- a/docker/prod/Dockerfile +++ b/docker/prod/Dockerfile @@ -1,4 +1,4 @@ -FROM ruby:2.7.2-buster +FROM ruby:2.7-buster MAINTAINER operations@openproject.com # Allow platform-specific additions. Valid values are: on-prem,saas,bahn diff --git a/docs/development/development-environment-docker/README.md b/docs/development/development-environment-docker/README.md index 2116fb180c..9fa300df0d 100644 --- a/docs/development/development-environment-docker/README.md +++ b/docs/development/development-environment-docker/README.md @@ -152,3 +152,20 @@ If the backend container is already running, it will be stopped. Instead it will be started in the foreground. This way you can debug using pry just as if you had started the server locally using `rails s`. You can stop it simply with Ctrl + C too. + +## Updates + +When a dependency of the image or the base image itself is changed you may need +rebuild the image. For instance when the Ruby version is updated you may run into +an error like the following when running `bin/compose setup`: + +``` +Creating core_backend_run ... done +Your Ruby version is 2.7.1, but your Gemfile specified ~> 2.7.2 +``` + +This means that the current image is out-dated. You can update it like this: + +``` +bin/comose build --pull +```