Skip to content

Instantly share code, notes, and snippets.

@soham2008xyz
Forked from thomasjsn/laravel-queue.service
Created January 19, 2018 10:36
Show Gist options
  • Save soham2008xyz/34852f869ce9b65864603987ff37924c to your computer and use it in GitHub Desktop.
Save soham2008xyz/34852f869ce9b65864603987ff37924c to your computer and use it in GitHub Desktop.
Laravel queue worker using systemd.
# Laravel queue worker using systemd
# ----------------------------------
#
# /lib/systemd/system/queue.service
#
# run this command to enable service:
# systemctl enable queue.service
[Unit]
Description=Laravel queue worker
[Service]
User=www-data
Group=www-data
Restart=on-failure
ExecStart=/usr/bin/php /path/to/laravel/artisan queue:work --daemon --env=production
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment