dont connect ldap on startup
Signed-off-by: jkoberg <jkoberg@owncloud.com>
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
Bugfix: Don't connect to ldap on startup
|
||||||
|
|
||||||
|
This leads to misleading error messages. Instead we connect on first request
|
||||||
|
|
||||||
|
https://github.com/owncloud/ocis/pull/6565
|
||||||
@@ -205,10 +205,10 @@ func (c ConnWithReconnect) GetConnection() (*ldap.Conn, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (c ConnWithReconnect) ldapAutoConnect(config Config) {
|
func (c ConnWithReconnect) ldapAutoConnect(config Config) {
|
||||||
l, err := c.ldapConnect(config)
|
var (
|
||||||
if err != nil {
|
l *ldap.Conn
|
||||||
c.logger.Error().Err(err).Msg("autoconnect could not get ldap Connection")
|
err error
|
||||||
}
|
)
|
||||||
|
|
||||||
for {
|
for {
|
||||||
select {
|
select {
|
||||||
|
|||||||
Reference in New Issue
Block a user