(ctx context.Context, container string, options client.ContainerInspectOptions)
| 107 | } |
| 108 | |
| 109 | func (d *DryRunClient) ContainerInspect(ctx context.Context, container string, options client.ContainerInspectOptions) (client.ContainerInspectResult, error) { |
| 110 | containerJSON, err := d.apiClient.ContainerInspect(ctx, container, options) |
| 111 | if err != nil { |
| 112 | id := "dryRunId" |
| 113 | for _, c := range d.containers { |
| 114 | if c.ID == container { |
| 115 | id = container |
| 116 | } |
| 117 | } |
| 118 | return client.ContainerInspectResult{ |
| 119 | Container: containerType.InspectResponse{ |
| 120 | ID: id, |
| 121 | Name: container, |
| 122 | State: &containerType.State{ |
| 123 | Status: containerType.StateRunning, // needed for --wait option |
| 124 | Health: &containerType.Health{ |
| 125 | Status: containerType.Healthy, // needed for healthcheck control |
| 126 | }, |
| 127 | }, |
| 128 | Mounts: nil, |
| 129 | Config: &containerType.Config{}, |
| 130 | NetworkSettings: &containerType.NetworkSettings{}, |
| 131 | }, |
| 132 | }, nil |
| 133 | } |
| 134 | return containerJSON, err |
| 135 | } |
| 136 | |
| 137 | func (d *DryRunClient) ContainerKill(ctx context.Context, container string, options client.ContainerKillOptions) (client.ContainerKillResult, error) { |
| 138 | return client.ContainerKillResult{}, nil |
no outgoing calls