Skip to content
Snippets Groups Projects

Resolve "Investigate GitLab-CI services don't reach each other"

1 file
+ 2
1
Compare changes
  • Side-by-side
  • Inline
@@ -88,9 +88,10 @@ func connect(addr string) (*amqp.Connection, error) {
@@ -88,9 +88,10 @@ func connect(addr string) (*amqp.Connection, error) {
for i := 0; i < retries; i++ {
for i := 0; i < retries; i++ {
conn, err := amqp.Dial(addr)
conn, err := amqp.Dial(addr)
if err == nil {
if err == nil {
 
logrus.Debug("Connected to RabbitMQ")
return conn, nil
return conn, nil
}
}
logrus.Info("could not connect to RabbitMQ. Retrying in 2 seconds.")
logrus.Error("could not connect to RabbitMQ. Retrying in 2 seconds.")
time.Sleep(2 * time.Second)
time.Sleep(2 * time.Second)
}
}
Loading