Skip to content

plugarchive: pack the same plugin to the same bytes - #50

Merged
ZergsLaw merged 1 commit into
masterfrom
fix/reproducible-plugin-archives
Oct 30, 2026
Merged

ZergsLaw merged 1 commit into
masterfrom
fix/reproducible-plugin-archives

Conversation

@ZergsLaw

Copy link
Copy Markdown
Contributor

Архив плагина записывал время файлов, владельца и маску прав машины, где шла сборка, поэтому пересборка того же бинарника давала архив с другим sha256, и plugins publish --force перезаливал все версии, а реплики их перекачивали. Теперь PackDir пишет epoch вместо времени, без владельцев и с режимами 0755/0644/0777: две сборки grpc/go:v1.6.2 дали одинаковый sha, тест TestPackDirIsReproducible без правки падает. Архивы, уже лежащие в хранилище, собраны по-старому, так что первый --force после этой версии перезальёт их один раз, дальше неизменённые версии не заливаются.

🤖 Generated with Claude Code

PackDir recorded mtimes, owners and the umask's share of each mode, so two
builds of an identical binary were two archives with different sha256s and
plugins publish --force re-uploaded every version and made every replica
refetch it. Entries now get the epoch, no owner and 0755/0644/0777.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@ZergsLaw
ZergsLaw merged commit 0d2fbdd into master Oct 30, 2026
12 checks passed
@ZergsLaw
ZergsLaw deleted the fix/reproducible-plugin-archives branch October 30, 2026 15:37
@ZergsLaw ZergsLaw mentioned this pull request Oct 30, 2026
ZergsLaw added a commit that referenced this pull request Oct 30, 2026
plugins publish builds and smoke-tests for the platform the service reports in
the new PluginsResponse.platform field, or --platform (#51), and packs plugins
reproducibly, so an unchanged rebuild is an identical archive that is not
uploaded again (#50).

Co-authored-by: Edgar Sipki <e.sipki@uzum.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant