updated the background logic for multiple docker servers