diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 1fda1c8b3aa..8b70ee682c4 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -11,11 +11,12 @@ on: jobs: push_to_registry: - if: github.repository == 'ipfs/go-ipfs' || github.event_name == 'workflow_dispatch' + if: github.repository == 'ipfs/go-ipfs' || github.repository == 'ipfs/kubo' || github.event_name == 'workflow_dispatch' name: Push Docker image to Docker Hub runs-on: ubuntu-latest env: - IMAGE_NAME: ipfs/go-ipfs + IMAGE_NAME: ipfs/kubo + LEGACY_IMAGE_NAME: ipfs/go-ipfs steps: - name: Check out the repo uses: actions/checkout@v2 diff --git a/Dockerfile b/Dockerfile index 913cde19b68..a3f223ccc27 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,7 +8,7 @@ RUN apt-get update && apt-get install -y \ ca-certificates \ fuse -ENV SRC_DIR /go-ipfs +ENV SRC_DIR /kubo # Download packages first so they can be cached. COPY go.mod go.sum $SRC_DIR/ @@ -51,7 +51,7 @@ FROM busybox:1.31.1-glibc LABEL maintainer="Steven Allen " # Get the ipfs binary, entrypoint script, and TLS CAs from the build container. -ENV SRC_DIR /go-ipfs +ENV SRC_DIR /kubo COPY --from=0 $SRC_DIR/cmd/ipfs/ipfs /usr/local/bin/ipfs COPY --from=0 $SRC_DIR/bin/container_daemon /usr/local/bin/start_ipfs COPY --from=0 $SRC_DIR/bin/container_init_run /usr/local/bin/container_init_run diff --git a/README.md b/README.md index 1b964931c97..d9f44a428f8 100644 --- a/README.md +++ b/README.md @@ -109,9 +109,12 @@ If your system is resource-constrained, we recommend: ### Docker -[![Docker Image Version (latest semver)](https://img.shields.io/docker/v/ipfs/go-ipfs?color=blue&label=go-ipfs%20docker%20image&logo=docker&sort=semver&style=flat-square&cacheSeconds=3600)](https://hub.docker.com/r/ipfs/go-ipfs/) +[![Docker Image Version (legacy name)](https://img.shields.io/docker/v/ipfs/go-ipfs?color=blue&label=go-ipfs%20docker%20image&logo=docker&sort=semver&style=flat-square&cacheSeconds=3600)](https://hub.docker.com/r/ipfs/go-ipfs/) + -More info on how to run kubo inside docker can be found [here](https://docs.ipfs.io/how-to/run-ipfs-inside-docker/). +More info on how to run kubo (go-ipfs) inside Docker can be found [here](https://docs.ipfs.io/how-to/run-ipfs-inside-docker/). ### Native Linux package managers diff --git a/bin/get-docker-tags.sh b/bin/get-docker-tags.sh index 809dfa4c2dc..e50ec69faf7 100755 --- a/bin/get-docker-tags.sh +++ b/bin/get-docker-tags.sh @@ -29,13 +29,15 @@ BUILD_NUM=$1 GIT_SHA1=${2:-$(git rev-parse HEAD)} GIT_SHA1_SHORT=$(echo "$GIT_SHA1" | cut -c 1-7) GIT_BRANCH=${3:-$(git symbolic-ref -q --short HEAD || echo "unknown")} -GIT_TAG=${4:-$(git describe --tags --exact-match || echo "")} +GIT_TAG=${4:-$(git describe --tags --exact-match 2> /dev/null || echo "")} -IMAGE_NAME=${IMAGE_NAME:-ipfs/go-ipfs} +IMAGE_NAME=${IMAGE_NAME:-ipfs/kubo} +LEGACY_IMAGE_NAME=${LEGACY_IMAGE_NAME:-ipfs/go-ipfs} echoImageName () { local IMAGE_TAG=$1 echo "$IMAGE_NAME:$IMAGE_TAG" + echo "$LEGACY_IMAGE_NAME:$IMAGE_TAG" } if [[ $GIT_TAG =~ ^v[0-9]+\.[0-9]+\.[0-9]+-rc ]]; then