title: Run laravel queue worker in docker
body: <p>I want to run <code>php artisan queue:work --daemon</code> command in docker file or docker-compose.yml
  but if I use command : xxx in docker compose file, ngin x returns 502.<br>
  I try to use bash file and again it's not working.<br>
  Can anyone help me?<br>
  I need to finish this today and really need help.<br>
  Docker compose file</p>
  
  <pre><code>version: '3'
  services:
  
    #Nginx Service
    webserver:
      image: nginx:alpine
      container_name: LibraryWebserver
      restart: unless-stopped
      tty: true
      ports:
        - "80:80"
        - "443:443"
      volumes:
        - ./:/var/www
        - ./nginx/conf.d/:/etc/nginx/conf.d/
      networks:
        - app-network
  
    #MySQL Service
    db:
      image: mysql:5.7.22
      container_name: Librarydb
      restart: unless-stopped
      tty: true
      ports:
        - "3306:3306"
      environment:
        MYSQL_DATABASE: library
        MYSQL_ROOT_PASSWORD: Library!23
        MYSQL_USER: root
        MYSQL_PASSWORD: Library!23
        SERVICE_TAGS: dev
        SERVICE_NAME: mysql
      networks:
        - app-network
      volumes:
        - dbdata:/var/lib/mysql
  
    #PHP Service
    app:
      build:
        context: .
        dockerfile: Dockerfile
      image: hoseinnormohamadi/lumen:Library
      container_name: Library
      restart: unless-stopped
      tty: true
      environment:
        SERVICE_NAME: app
        SERVICE_TAGS: dev
      working_dir: /var/www
      volumes:
        - ./:/var/www
      networks:
        - app-network
  #Docker Networks
  networks:
    app-network:
      driver: bridge
  #Volumes
  volumes:
    dbdata:
      driver: local
  
  </code></pre>