Following the @Intu answer. You need a background service, otherwise spring will fail. Adding a simple nginx worked to me.
services: example: image: nginx