laravel queue service in docker container

I’ve 3 docker containers, php7 nginx and mariadb each are linked up and serve simple wordpress sites.

I’d like to add laravel project to the bunch. It all works great except laravel services that I need to run, e.g. queue listener and scheduler cron. How do you recommend dealing with these?

  • fabric8io docker-maven-plugin in Windows
  • file system issue when i use vagrant+docker on windows
  • Docker run rm with rest API
  • Docker container with Node and Express on Mac, not showing in browser?
  • Setting a static IP to docker container using LXC driver
  • Using zookeeper for service discovery of mesos slaves running docker
  • Docker - decrease pull size
  • Create Docker Containers and then copy Ansible playbook to them
  • Why is my docker CI image not reproducible / running everywhere
  • How to start a docker container (ubuntu image)
  • Starting an app fails
  • docker restore fails - when checkpointed with active TCP connections - criu
  • One Solution collect form web for “laravel queue service in docker container”

    You might want to consider using Docker Compose to orchestrate multiple containers together. For example, you’d have a Docker Compose file that declared a Docker network, and three containers:

    1. Message Queue
    2. Cron Scheduled Tasks
    3. Laravel application + PHP + Web Server

    As long as you add each of the containers to the same network, they’ll be able to communicate with each other. Another benefit of using Docker Compose is that scaling containers is much easier.

    Here’s the reference documentation for Docker Compose YAML files:

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.