deps(ipfs): bump kubo to v0.41.0 and fix removed/no-op config#1168
deps(ipfs): bump kubo to v0.41.0 and fix removed/no-op config#1168odesenfans wants to merge 1 commit into
Conversation
Kubo 0.38 merged Reprovider into Provide and removed Reprovider.* keys; the init script's `ipfs config Reprovider.Strategy 'pinned'` now errors on every container start. Switch to `Provide.Strategy`. The --enable-pubsub-experiment daemon flag became a no-op in kubo 0.38; it only logs a deprecation error and does NOT enable pubsub. Since Pubsub.Enabled defaults to false and pyaleph relies on IPFS pubsub for peer liveness, drop the flag and set `Pubsub.Enabled=true` in config. The --migrate flag is preserved so the repo migrates from v17 to v18 automatically on first boot under 0.41.
foxpatch-aleph
left a comment
There was a problem hiding this comment.
Correctly bumps kubo from v0.37.0 to v0.41.0 across all 4 compose files. Replaces the removed Reprovider.Strategy config key with Provide.Strategy, removes the no-op --enable-pubsub-experiment daemon flag (sets Pubsub.Enabled via config instead), and preserves all other settings. All changes are verified against kubo v0.41.0 source and config docs. Clean, well-researched, and focused PR.
deployment/scripts/001-update-ipfs-config.sh (line 21): Verified against kubo v0.41.0 source: Pubsub.Enabled is type flag (boolean, default false), and --json 'true' correctly sets a JSON boolean. The --enable-pubsub-experiment daemon flag was confirmed to be a no-op (only logs deprecation error, value not wired up) at cmd/ipfs/kubo/daemon.go:424-428.
deployment/scripts/001-update-ipfs-config.sh (line 17): Verified against kubo v0.41.0 config.md: Reprovider.Strategy is REMOVED and replaced by Provide.Strategy. Value 'pinned' is a documented valid strategy.
deployment/docker-build/docker-compose.yml (line 55): Pre-existing (not introduced by this PR): bind mount ./001-update-ipfs-config.sh does not exist at deployment/docker-build/001-update-ipfs-config.sh. The script lives at deployment/scripts/001-update-ipfs-config.sh.
deployment/docker-build/dev/docker-compose.yml (line 125): Pre-existing (not introduced by this PR): same bind mount issue as the other compose files.
deployment/samples/docker-compose/docker-compose.yml (line 113): Pre-existing (not introduced by this PR): same bind mount issue as the other compose files.
deployment/samples/docker-monitoring/docker-compose.yml (line 115): Pre-existing (not introduced by this PR): same bind mount issue as the other compose files.
Summary
Bumps the IPFS image from
kubo:v0.37.0tokubo:v0.41.0across alldeployment compose files and fixes two configuration items that became
broken in the intervening releases.
1.
Reprovider.*config keys REMOVED in 0.41Kubo 0.38 merged the
ProviderandReprovidersections into a singleProvidesection. The v0.41docs/config.mdexplicitly marks
Reprovider.Strategyas REMOVED (andReprovider.Interval→ useProvide.DHT.Interval).Our init script set this value on every container start
(
ipfs config Reprovider.Strategy 'pinned'), so--migratedoes nothelp: the line errors on each boot. Switched to
Provide.Strategy.2.
--enable-pubsub-experimentis now a no-op (silent breakage)Per v0.41 source
(
cmd/ipfs/kubo/daemon.go):The flag value is no longer wired up, and
Pubsub.Enableddefaults tofalse. Since pyaleph relies on IPFS pubsub for peer liveness(
src/aleph/services/ipfs/pubsub.py,services/peers/publish.py,services/peers/monitor.py), leaving this unchanged would silentlydisable pubsub.
Fix: removed the dead flag from the daemon command and added
ipfs config Pubsub.Enabled --json 'true'to the init script.Preserved
--migrateis kept so the on-disk repo migrates from v17 to v18 onfirst boot under 0.38+.
Operator upgrade notes
/data/ipfsvolume was previously owned byroot(e.g. an older deployment that ran the container as root), the new
image runs as
ipfs(UID 1000) and the entrypoint's auto-chown canbe slow on large volumes. Operators may want to run a manual
chown -R 1000:100 /var/lib/docker/volumes/<...>/_dataahead of thebump. This is unchanged behaviour vs. 0.37 (the kubo Dockerfile has
set
ipfs:usersownership for years); only volumes with mismatchedhistory are affected.
Test plan
kubo:v0.37.0,confirm: daemon starts,
ipfs config Pubsub.Enabledreturnstrue,ipfs config Provide.Strategyreturnspinned, noReprovider.Strategyerrors in001-update-ipfs-config.shlogs.pubsub topic after upgrade.