ipfs / ipfs/kubo

Deprecate and remove the shutdown command

Open
#7,866 1 comment 1 reaction 0 assignees View on GitHub
kind/bug need/triage topic/api topic/rpc-api topic/security
Dominant language
Go
Stars
17.1k
Forks
3.2k
Avg merge
3d 18h
Merged PRs (30d)
11

Description

During this week's triage of https://github.com/ipfs/go-ipfs/issues/7865 we realized that `shutdown` command exposed over HTTP API is pretty risky thing to have.

IIUC go-ipfs already supports shutdown signals the right way:

https://github.com/ipfs/go-ipfs/blob/ea77213e31ef2b3cad81d40bf82bb9baef3ea7b6/cmd/ipfs/util/signal.go#L79

I propose deprecation and removal of the `shutdown` command.
Either someone stops `ipfs daemon` via ^C or send a proper signal to the process:
No need of having third way which is exposed via HTTP API.

cc @aschmahmann @Stebalien @whyrusleeping thoughts? is there any reason to keep it?

Contributor guide

Open the contributing guide

Research direction

Start by reviewing the shutdown command and where it is exposed through the HTTP API, then compare that behavior with cmd/ipfs/util/signal.go at the referenced signal handling code. Confirm the deprecation and removal scope with maintainers, and consider the work done when shutdown is no longer exposed and signal-based termination remains supported.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
api, cli
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.