Skip to content

[Request]: Add container restart command #2219

Description

@Ronitsabhaya75

Feature or enhancement request details

Currently there's no way to restart a container with a single command you have to run container stop followed by container start. Every major container tool (Docker, Podman, nerdctl) provides a restart command, and it would be nice to have it here too.

The command would:

  • Accept one or more container IDs, or --all to restart everything
  • Support --time and --signal options for the stop phase (same as container stop)
  • Stop the container if it's running, then start it back up in detached mode
  • Simply start already-stopped containers (matching Docker's behavior)

This is a CLI-shape change since it adds a new subcommand under the Container group.

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions