Skip to content

Commit 51a9a54

Browse files
authored
fix: autoremove container in examples (#314)
When running the examples they leave unnecessary containers hanging around. Add AutoRemove: true, to automatically remove them.
1 parent c39f57f commit 51a9a54

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

examples/emulator_runner.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ func startEmulator() error {
9393
Image: "gcr.io/cloud-spanner-emulator/emulator",
9494
ExposedPorts: nat.PortSet{"9010": {}},
9595
}, &container.HostConfig{
96+
AutoRemove: true,
9697
PortBindings: map[nat.Port][]nat.PortBinding{"9010": {{HostIP: "0.0.0.0", HostPort: "9010"}}},
9798
}, nil, nil, "")
9899
if err != nil {

0 commit comments

Comments
 (0)