I am deploying to Vapor. The queue/worker is not working.
YAML:
id: 56969
name: simply-analyze
environments:
production:
memory: 1024
cli-memory: 512
runtime: 'php-8.2:al2'
database: simply-analyze
build:
- 'composer install --no-dev'
- 'php artisan event:cache'
- 'npm ci && npm run build && rm -rf node_modules'
deploy:
- 'php artisan migrate --force'
Locally the queue/worker works fine, in console/kernel:
protected function schedule(Schedule $schedule): void
{
/*
* Let's add jobs to the queue here.
*/
// $schedule->job(new GenerateConversation)->everyTenSeconds(); // Add this job to the queue.
$schedule->job(new Analyze)->everyTwoSeconds(); // Add this job to the queue.
}
I suspect my YAML isn't set up right?
When developing locally, I do queue:work and schedule:run and it works ok.
I have changed my YAML to this, but no luck, the queue worker isn't doing anything...
id: 56969
name: simply-analyze
environments:
queue-concurrency: 3
queues:
- default: 3
production:
memory: 1024
cli-memory: 512
runtime: 'php-8.2:al2'
database: simply-analyze
build:
- 'composer install --no-dev'
- 'php artisan event:cache'
- 'npm ci && npm run build && rm -rf node_modules'
deploy:
- 'php artisan migrate --force'