skip to content

For an organisation's repositories and registries, which version names would you freeze, which may move, and how would you handle a bad release?

level: principalimportance: should knowfreq 30%

answer

  1. versions frozen, aliases move
  2. defaults differ per server
  3. who may change the setting
  4. a takedown without reuse

basics

~20 s

Freeze every release version and version-shaped tag on every server, allow only named aliases and snapshots to move, and fix bad releases with new versions. Rare takedowns delete with approval and never reuse the number.

solid answer

~50 s

I would set one rule and enforce it per server: **releases are frozen, aliases move, and deploys record versions or digests**. Release repositories refuse redeploys; container registries freeze version-shaped tags while named aliases such as `latest` or `stable` stay mutable; snapshots live only in snapshot repositories. Because defaults differ (Harbor lets tags be re-pushed until rules exist, nuget.org rejects duplicates while other NuGet sources may replace, Artifactory's Docker repositories accept tag overwrites and can keep earlier revisions), each server is audited, and only a central team may change the settings. A bad release is fixed by a new version and marked unsafe. A true takedown, such as a leaked secret or a licence problem, is an approved delete that never reuses the number. The cost is friction, since typos need new versions and retag-based promotion must change, plus storage, which retention handles.

go deeper

for a junior

Recall the principle: release versions are frozen, aliases such as latest can move, and a bad release is fixed with a new version.

for a middle

Explain how each server expresses the rule differently, from refusing duplicate packages to Harbor's immutability rules, and why aliases stay mutable.

for a senior

Show you can audit an estate for overwrite gaps and run a takedown as an approved delete that retires the number rather than an overwrite.

for a principal

Own the tradeoff: strictness against friction and storage, which aliases are allowed, who may change the settings, and how the guarantee is verified as the estate grows.

## The decision a lead owns Every team agrees in principle that releases should not change. The open question is **how strict the organisation is, where it enforces it, and what the exceptions are**. There is no single right answer: a stricter policy buys reproducibility and audit strength and costs developer friction and storage. A lead has to choose and then make the choice hold across every repository and registry, not just the one where it was first discussed. ## A workable default 1. **Freeze every release version.** Each release repository in the repository manager refuses a second upload to an existing path. Package registries that already refuse duplicates, such as the npm registry, need no extra work. 2. **Freeze version-shaped container tags.** Registries are configured so tags like `2.4.1` cannot be re-pushed; in Harbor that means immutability rules on every project. 3. **Allow named aliases to move**: `latest`, `stable`, npm dist-tags, and nothing else. Write the list down. 4. **Keep snapshots in snapshot repositories** and keep them out of anything released. 5. **Deploys and records use versions or digests**, never aliases. ## Why "set it once" is not enough Defaults differ, so the policy has to be applied server by server: | Server | Default for a repeat upload | |---|---| | npm public registry | Rejected; a used version can never be reused | | nuget.org | Rejected with `409`; other NuGet sources may support replacing | | Harbor project | Tag can be re-pushed until immutability rules are added | | Artifactory Docker repository | Tag can be overwritten; **Docker Tag Retention** controls how many overwritten revisions are kept | The questions for each server: is the refusal on, can a project or team switch it off, and who holds that right? In Harbor, a project's Maintainer or Project Admin can create or deactivate immutability rules, so a lead who wants an organisation-wide guarantee either keeps that role central or audits every project regularly. ## Handling a bad release Most bad releases need no exception at all: - **Normal defect**: publish the next version, steer consumers to it, mark the broken one deprecated or unlisted. - **Security or legal takedown** (a leaked credential, content the company may not distribute): delete with a recorded approval, notify consumers whose builds will now fail, and **never reuse the number**. npm's own policy works this way: even after an unpublish, the name and version stay retired. The exception is a delete, never an overwrite. A delete makes builds fail loudly; an overwrite makes them succeed with different content. ## What the policy costs - **Friction.** A typo in a release means a new version. Making releases cheap to cut keeps that from hurting. - **Promotion design.** Re-pointing an existing frozen tag fails, so promotion must copy by digest or add new tags. - **Storage.** Frozen releases accumulate; a retention policy, owned separately, decides what may be removed and when. - **Exceptions creep.** Each excluded alias is a name that can move under someone, so keep the exclusion list short and named. ## Rolling it out Turning the policy on across an existing estate is a migration, not a switch: 1. **Inventory** every release repository and registry project, with its current overwrite behaviour and who can change it. 2. **Turn on refusal for new content first**, so nothing new can be overwritten while the old state is studied. 3. **Look for past overwrites** in repository history and in hash mismatches reported by builds, and decide which content each affected version should mean. 4. **Publish the alias list** (which names may move, and who moves them), so teams stop relying on version-shaped tags that will now freeze. 5. **Move the setting under central ownership**, through templates for new repositories and projects plus a regular audit. ## Signals the policy is working - Every release repository and registry project is listed with its setting, and the list is checked automatically. - Incidents involving "same version, different bytes" drop to zero. - Deploy records always name a version or digest that resolves to the same content a year later.

  • Would you ever allow a team to overwrite a release in place?
    No. Where content truly must go, the answer is an approved delete that retires the number, so dependent builds fail loudly. An overwrite lets them succeed with different bytes, and caches keep both copies. If a team keeps asking, the real problem is that cutting a new release is too expensive, and that is the thing to fix.
  • How do you keep the policy true as new projects and repositories appear?
    Make immutability part of how repositories and registry projects are created, not a later fix: templates with the refusal on, central ownership of the setting, and a periodic audit listing every release repository and project with its current rule. Harbor rules are per project, so new projects start unprotected unless creation adds them.

  • One global switch makes every format and registry immutable.
  • Freezing latest too is the safest choice.
  • A takedown should overwrite the release with a clean build.
  • Immutability costs nothing, so there is no tradeoff to weigh.
  • Package registries all refuse duplicates, so only images need settings.