code: public function onKernelTerminate(PostResponseEvent $event): void
      {
          if (!$this->framework->isInitialized() || !$this->canRunController($event->getRequest())) {
              return;
          }
  
          /** @var FrontendCron $controller */
          $controller = $this->framework->createInstance(FrontendCron::class);
          $controller->run();
      }
docs: Runs the command scheduler.