mirror of
https://github.com/bingohuang/docker-labs.git
synced 2025-07-16 03:07:26 +08:00
Change default dind image and prevent session panic
This commit is contained in:
parent
cab8eef9da
commit
939c045198
@ -41,7 +41,7 @@ func init() {
|
||||
|
||||
func getDindImageName() string {
|
||||
dindImage := os.Getenv("DIND_IMAGE")
|
||||
defaultDindImageName = "docker:1.12.3-dind"
|
||||
defaultDindImageName = "franela/pwd-1.12.3-experimental-dind"
|
||||
if len(dindImage) == 0 {
|
||||
dindImage = defaultDindImageName
|
||||
}
|
||||
|
@ -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 {
|
||||
if i.conn != nil {
|
||||
i.conn.Close()
|
||||
}
|
||||
if err := DeleteContainer(i.Name); err != nil {
|
||||
log.Println(err)
|
||||
return err
|
||||
|
Loading…
x
Reference in New Issue
Block a user