fix: Allow coderd to exit on error channel (#1355)

coderd would fail silently if this was called, because connections
would never drain. HashiCorp's hc-install package broke today,
and we couldn't notice because this was hanging!
This commit is contained in:
Kyle Carberry
2022-05-10 02:19:20 +00:00
committed by GitHub
parent 3660483b97
commit e6f1ce1fb2
+1
View File
@@ -361,6 +361,7 @@ func server() *cobra.Command {
return err
}
case err := <-errCh:
shutdownConns()
closeCoderd()
return err
case <-stopChan: