make bind-serve-once into a general server loop