サービスでコマンドを実行する必要があります
app/console fos:elastica:populate --no-reset --index=profile --type=team
ターミナルではすべて正常に動作しますが、サービスで実行する必要があります
$application = new \Symfony\Bundle\FrameworkBundle\Console\Application($this->kernel);
$application->setAutoExit(false);
//Upload in Elastic
$options = array('command' => 'fos:elastica:populate', "--no-reset" => true, "--index=profile" => true, "--type=team" => true);
$upload = $application->run(new \Symfony\Component\Console\Input\ArrayInput($options));
エラーがあります:
[InvalidArgumentException]
The "--index=profile" option does not exist.