Merge pull request #50992 from thaJeztah/remove_backend_execinspect

daemon/server/backend: remove ExecInspect, ExecProcessConfig alias
This commit is contained in:
Sebastiaan van Stijn
2025-09-17 12:38:50 +02:00
committed by GitHub
3 changed files with 4 additions and 12 deletions

View File

@@ -184,7 +184,7 @@ func (daemon *Daemon) getInspectData(daemonCfg *config.Config, ctr *container.Co
// ContainerExecInspect returns low-level information about the exec
// command. An error is returned if the exec cannot be found.
func (daemon *Daemon) ContainerExecInspect(id string) (*backend.ExecInspect, error) {
func (daemon *Daemon) ContainerExecInspect(id string) (*containertypes.ExecInspectResponse, error) {
e := daemon.execCommands.Get(id)
if e == nil {
return nil, errExecNotFound(id)
@@ -209,11 +209,11 @@ func (daemon *Daemon) ContainerExecInspect(id string) (*backend.ExecInspect, err
privileged = &e.Privileged
}
return &backend.ExecInspect{
return &containertypes.ExecInspectResponse{
ID: e.ID,
Running: e.Running,
ExitCode: e.ExitCode,
ProcessConfig: &backend.ExecProcessConfig{
ProcessConfig: &containertypes.ExecProcessConfig{
Tty: e.Tty,
Entrypoint: e.Entrypoint,
Arguments: e.Args,

View File

@@ -149,14 +149,6 @@ type ExecStartConfig struct {
ConsoleSize *[2]uint `json:",omitempty"`
}
// ExecInspect holds information about a running process started
// with docker exec.
type ExecInspect = container.ExecInspectResponse
// ExecProcessConfig holds information about the exec process
// running on the host.
type ExecProcessConfig = container.ExecProcessConfig
// CreateImageConfig is the configuration for creating an image from a
// container.
type CreateImageConfig struct {

View File

@@ -15,7 +15,7 @@ import (
// execBackend includes functions to implement to provide exec functionality.
type execBackend interface {
ContainerExecCreate(name string, options *container.ExecCreateRequest) (string, error)
ContainerExecInspect(id string) (*backend.ExecInspect, error)
ContainerExecInspect(id string) (*container.ExecInspectResponse, error)
ContainerExecResize(ctx context.Context, name string, height, width uint32) error
ContainerExecStart(ctx context.Context, name string, options backend.ExecStartConfig) error
ExecExists(name string) (bool, error)