feat: add docker stub for deprecated ipfs/go-ipfs name (#10998)
* feat: add docker stub for deprecated ipfs/go-ipfs name implements docker part of #10941 by creating a stub image that redirects users from ipfs/go-ipfs to ipfs/kubo changes: - add stub dockerfile and script in .github/legacy/ - modify docker-image.yml to push stub to ipfs/go-ipfs with same tags as ipfs/kubo - remove ipfs/go-ipfs from get-docker-tags.sh to prevent docker-hub job from pushing to legacy name - stub displays clear deprecation message directing users to ipfs/kubo:release * docs: add v0.39 changelog highlight for go-ipfs deprecation
Marcin Rataj committed
Oct 2, 2025 at 20:08 UTC
35ba5091a50606d95978677c643b1ecde5515d8b
5 files changed
+107
-3
.github/legacy/Dockerfile.goipfs-stub
new
+26
@@ -0,0 +1,26 @@
1
+# syntax=docker/dockerfile:1
2
+# Stub Dockerfile for the deprecated 'ipfs/go-ipfs' image name.
3
+# This image redirects users to the new 'ipfs/kubo' name.
4
+FROM busybox:stable-glibc
5
+
6
+# Copy stub entrypoint that displays deprecation message
7
+COPY .github/legacy/goipfs_stub.sh /usr/local/bin/ipfs
8
+
9
+# Make it executable
10
+RUN chmod +x /usr/local/bin/ipfs
11
+
12
+# Use the same ports as the real image for compatibility
13
+EXPOSE 4001 4001/udp 5001 8080 8081
14
+
15
+# Create ipfs user for consistency
16
+ENV IPFS_PATH=/data/ipfs
17
+RUN mkdir -p $IPFS_PATH \
18
+ && adduser -D -h $IPFS_PATH -u 1000 -G users ipfs \
19
+ && chown ipfs:users $IPFS_PATH
20
+
21
+# Run as ipfs user
22
+USER ipfs
23
+
24
+# The stub script will run and exit with an error message
25
+ENTRYPOINT ["/usr/local/bin/ipfs"]
26
+CMD ["daemon"]
.github/legacy/goipfs_stub.sh
new
+20
@@ -0,0 +1,20 @@
1
+#!/bin/sh
2
+# Stub script for the deprecated 'ipfs/go-ipfs' Docker image.
3
+# This informs users to switch to 'ipfs/kubo'.
4
+
5
+cat >&2 <<'EOF'
6
+ERROR: The name 'go-ipfs' is no longer used.
7
+
8
+Please update your Docker scripts to use 'ipfs/kubo' instead of 'ipfs/go-ipfs'.
9
+
10
+For example:
11
+ docker pull ipfs/kubo:release
12
+
13
+More information:
14
+ - https://github.com/ipfs/kubo#docker
15
+ - https://hub.docker.com/r/ipfs/kubo
16
+ - https://docs.ipfs.tech/install/run-ipfs-inside-docker/
17
+
18
+EOF
19
+
20
+exit 1
.github/workflows/docker-image.yml
+51
-1
@@ -39,7 +39,8 @@ jobs:
39
timeout-minutes: 15
40
env:
41
IMAGE_NAME: ipfs/kubo
42
- LEGACY_IMAGE_NAME: ipfs/go-ipfs
42
+ outputs:
43
+ tags: ${{ steps.tags.outputs.value }}
44
steps:
45
- name: Check out the repo
46
uses: actions/checkout@v5
@@ -140,3 +141,52 @@ jobs:
141
cache-to: |
142
type=gha,mode=max
143
type=registry,ref=${{ env.IMAGE_NAME }}:buildcache,mode=max
144
+
145
+ # Build and push stub image to the legacy ipfs/go-ipfs name
146
+ # This redirects users to use ipfs/kubo instead
147
+ legacy-name:
148
+ needs: docker-hub
149
+ if: github.repository == 'ipfs/kubo' || github.event_name == 'workflow_dispatch'
150
+ name: Push stub to legacy ipfs/go-ipfs name
151
+ runs-on: ubuntu-latest
152
+ timeout-minutes: 5
153
+ env:
154
+ LEGACY_IMAGE_NAME: ipfs/go-ipfs
155
+ steps:
156
+ - name: Check out the repo
157
+ uses: actions/checkout@v5
158
+
159
+ - name: Set up QEMU
160
+ uses: docker/setup-qemu-action@v3
161
+
162
+ - name: Set up Docker Buildx
163
+ uses: docker/setup-buildx-action@v3
164
+
165
+ - name: Log in to Docker Hub
166
+ uses: docker/login-action@v3
167
+ with:
168
+ username: ${{ vars.DOCKER_USERNAME }}
169
+ password: ${{ secrets.DOCKER_PASSWORD }}
170
+
171
+ - name: Convert tags to legacy image name
172
+ id: legacy_tags
173
+ run: |
174
+ TAGS="${{ github.event.inputs.tags || needs.docker-hub.outputs.tags }}"
175
+ if ! echo "$TAGS" | grep -q "kubo"; then
176
+ echo "ERROR: Tags must contain kubo image name"
177
+ exit 1
178
+ fi
179
+ echo "value<<EOF" >> $GITHUB_OUTPUT
180
+ echo "$TAGS" | sed "s|ipfs/kubo|$LEGACY_IMAGE_NAME|g" >> $GITHUB_OUTPUT
181
+ echo "EOF" >> $GITHUB_OUTPUT
182
+ shell: bash
183
+
184
+ - if: github.event_name != 'workflow_dispatch' || github.event.inputs.push == 'true'
185
+ name: Build and push legacy stub image
186
+ uses: docker/build-push-action@v6
187
+ with:
188
+ platforms: linux/amd64,linux/arm/v7,linux/arm64/v8
189
+ context: .
190
+ push: true
191
+ file: ./.github/legacy/Dockerfile.goipfs-stub
192
+ tags: ${{ steps.legacy_tags.outputs.value }}
bin/get-docker-tags.sh
-2
@@ -29,12 +29,10 @@ GIT_BRANCH=${3:-$(git symbolic-ref -q --short HEAD || echo "unknown")}
29
GIT_TAG=${4:-$(git describe --tags --exact-match 2> /dev/null || echo "")}
30
31
IMAGE_NAME=${IMAGE_NAME:-ipfs/kubo}
32
-LEGACY_IMAGE_NAME=${LEGACY_IMAGE_NAME:-ipfs/go-ipfs}
32
33
echoImageName () {
34
local IMAGE_TAG=$1
35
echo "$IMAGE_NAME:$IMAGE_TAG"
37
- echo "$LEGACY_IMAGE_NAME:$IMAGE_TAG"
36
}
37
38
if [[ $GIT_TAG =~ ^v[0-9]+\.[0-9]+\.[0-9]+-rc ]]; then
docs/changelogs/v0.39.md
+10
@@ -18,6 +18,16 @@ This release was brought to you by the [Shipyard](https://ipshipyard.com/) team.
18
19
### 🔦 Highlights
20
21
+#### 🪦 Deprecated `go-ipfs` name no longer published
22
+
23
+The `go-ipfs` name was deprecated in 2022 and renamed to `kubo`. Starting with this release, we have stopped publishing Docker images and distribution binaries under the old `go-ipfs` name.
24
+
25
+Existing users should switch to:
26
+- Docker: `ipfs/kubo` image (instead of `ipfs/go-ipfs`)
27
+- Binaries: download from https://dist.ipfs.tech/kubo/ or https://github.com/ipfs/kubo/releases
28
+
29
+For Docker users, the legacy `ipfs/go-ipfs` image name now shows a deprecation notice directing you to `ipfs/kubo`.
30
+
31
### 📦️ Important dependency updates
32
33
- update `go-ds-pebble` to [v0.5.2](https://github.com/ipfs/go-ds-pebble/releases/tag/v0.5.2)