fix(master): remember the tag's deployed digest after any tag job (#9)
Renames last_auto_digest to last_tag_digest. FinishJob sets it to the pinned digest after any successful job whose to_ref had no digest, so a rollback holds however the update was started.
This commit is contained in:
@@ -129,12 +129,13 @@ multi-arch image the digest is the index digest, the same one `docker inspect` s
|
||||
|
||||
- **What counts as new.** A digest different from the one the service runs becomes the
|
||||
service's *available* version (the overview badge, source `poll`). A digest the master
|
||||
already suggested is not suggested again. A service in **auto** mode also gets one update
|
||||
job to `repo:tag` per digest (the agent resolves the digest itself, so agents on protocol
|
||||
version 2 keep working); the master remembers that digest in `services.last_auto_digest`
|
||||
and does not start another job for it, whether the job failed or the user rolled back
|
||||
afterwards. If the service already had a job when the digest was found, the next cycle
|
||||
tries again.
|
||||
already suggested is not suggested again. A service in **auto** mode also gets an update
|
||||
job to `repo:tag` (the agent resolves the digest itself, so agents on protocol version 2
|
||||
keep working). The master remembers the newest digest it started or deployed for the tag
|
||||
in `services.last_tag_digest` (set when polling starts a job and when any plain tag job
|
||||
succeeds, whoever started it) and starts no job for that digest again, whether the job
|
||||
failed or the user rolled back afterwards. If the service already had a job when the
|
||||
digest was found, the next cycle tries again.
|
||||
- **What is not polled.** Services that follow no tag (`repo@digest`), `build:` services, and
|
||||
services without a registry digest (locally built images). The service page says which.
|
||||
The updater's own services and plain containers are polled, so their badge works, but
|
||||
@@ -173,11 +174,11 @@ digest-pinned or tagless versions need an agent speaking protocol version 3 (thi
|
||||
release); on an older agent the job fails with "agent too old to deploy a pinned version
|
||||
(needs protocol 3)".
|
||||
|
||||
A service in **auto** mode stays auto after a rollback. Polling does not undo the rollback:
|
||||
it started at most one job per digest, so the service stays on the older version until a
|
||||
new digest of the followed tag appears. The newer version it was rolled back from stays
|
||||
marked as available. A webhook that names a tag still starts a job for an auto service
|
||||
every time, so a CI push moves it forward again.
|
||||
A service in **auto** mode stays auto after a rollback. Polling does not undo it: the
|
||||
service stays on the older version until the registry shows a digest of the followed tag
|
||||
that differs from the newest one the master deployed. The newer version it was rolled back
|
||||
from stays marked as available. A webhook that names a tag still starts a job for an auto
|
||||
service every time, so a CI push moves it forward again.
|
||||
|
||||
## Adding agents
|
||||
|
||||
|
||||
Reference in New Issue
Block a user