Copy the release version into image builds

cc2aae44a9d4 · AtlantisPleb · · parent 8261bc545c9e

Copy the release version into image builds

Deploy story

What this commit did to the running system — joined from the forge receipt chain, the part a commit page elsewhere cannot show.

built
0 modules in 9.3 s
built
0 modules in 16.1 s
built
4 modules in 20.6 s
deployed
live · 0 modules on 3 nodes · push→live 2483.2 s
deployed
live · 0 modules on 3 nodes · push→live —
deployed
needs_rolling_replace · 0 modules on 0 nodes · push→live —
deployed
live · 4 modules on 3 nodes · push→live —
deployed
needs_rolling_replace · 4 modules on 0 nodes · push→live —

Changed files

  • modified Dockerfile
  • modified docs/deploymodes.md
  • modified test/openagents/release/appup_test.exs

Diff

3 files changed, +7 -1

Dockerfile modified +1 -1

@@ -84,7 +84,7 @@ RUN mix local.hex "${HEX_VERSION}" --force \

84 84
ENV MIX_ENV="prod"
85 85
86 86
# install mix dependencies
87
COPY mix.exs mix.lock ./
87
COPY VERSION mix.exs mix.lock ./
88 88
RUN mix deps.get --only $MIX_ENV
89 89
RUN mkdir config
90 90
docs/deploymodes.md modified +5

@@ -201,6 +201,11 @@ application specification with that identity, and each deployment node

201 201
compares it with its running release. Leaving `VERSION` behind causes every
202 202
later direct candidate to fail with `runtime_toolchain_mismatch`.
203 203
204
Startup and migration jobs must read the installed release version from
205
`/app/releases/start_erl.data`. Do not embed a release version in instance
206
metadata or an operator script. A hard-coded value can leave normal web startup
207
healthy while making the next migration or release command unusable.
208
204 209
## Receipts and status
205 210
206 211
`/status` and `/api/status` expose the active Forge lane, current target,
test/openagents/release/appup_test.exs modified +1

@@ -48,6 +48,7 @@ defmodule OpenAgents.Release.AppupTest do

48 48
49 49
    assert File.read!(@dockerfile) =~ "ARG OPENAGENTS_RELEASE_VSN\n"
50 50
    refute File.read!(@dockerfile) =~ "ARG OPENAGENTS_RELEASE_VSN="
51
    assert File.read!(@dockerfile) =~ "COPY VERSION mix.exs mix.lock ./"
51 52
  end
52 53
53 54
  test "covers a changed module the fixed proof set never named" do

This page updates live while a promote is in flight · changelog