Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unknown command: schedule/run #77

Open
acai2046 opened this issue Oct 22, 2023 · 0 comments
Open

Unknown command: schedule/run #77

acai2046 opened this issue Oct 22, 2023 · 0 comments

Comments

@acai2046
Copy link

What steps will reproduce the problem?

Unknown command: schedule/run
Caused by: Exception 'yii\base\InvalidRouteException' with message 'Unable to resolve the request "schedule/run".'

What's expected?

/console/config/schedule.php

`<?php
use omnilight\scheduling\Schedule;

/**

@var Schedule $schedule
*/
$commandBathPath = Yii::getAlias('@app') . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . 'yii ';
if(YII_ENV_PROD) {
$schedule->exec($commandBathPath . 'spider/process-email-pic')->everyTenMinutes();
$schedule->exec($commandBathPath . 'email/send-from-queue')->everyNMinutes(2);
}`

Additional info

Q A
Yii version yii2-app-advanced
PHP version PHP version: 7.2.34
Operating system Welcome to Ubuntu 23.04 (GNU/Linux 6.2.0-32-generic x86_64)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant