mirror of
https://github.com/bingohuang/docker-labs.git
synced 2025-10-05 01:43:22 +08:00
Change default dind image and prevent session panic
This commit is contained in:
@@ -66,7 +66,9 @@ func CloseSession(s *Session) error {
|
||||
wsServer.BroadcastTo(s.Id, "session end")
|
||||
log.Printf("Starting clean up of session [%s]\n", s.Id)
|
||||
for _, i := range s.Instances {
|
||||
i.conn.Close()
|
||||
if i.conn != nil {
|
||||
i.conn.Close()
|
||||
}
|
||||
if err := DeleteContainer(i.Name); err != nil {
|
||||
log.Println(err)
|
||||
return err
|
||||
|
Reference in New Issue
Block a user