Nitin Jamdhade
Nitin Jamdhade

Reputation: 11

how to use api of elasticsearch in shopware's cron?

i'm setting up a cronjob for reindexing Elasticsearch index in shopware, problem is that to execute "php bin/console sw:es:index:populate" in cronjob. please hepl me.

i tried to add service for IndexPopulateCommand however i cant access it from cron

Upvotes: 1

Views: 152

Answers (1)

mnaczenski
mnaczenski

Reputation: 1626

You can already run "php bin/console sw:es:index:populate" with a server-side cronjob. It's not recommended to use the cron-system of shopware for such a long-running task. There is no need for this, because you can already use cli-commands in linux crontab.

Upvotes: 0

Related Questions