Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

General Questions

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

cron tasks and database not defined in SS 2.4




26 April 2013 at 7:26pm Community Member, 30 Posts

Hi there,

I'm stuck on a problem with schedulded tasks. I have read this
and this
and everything seems to be working quite well on my local host but on the live server, the database connection is not initialized so when I call any dataobject, it fails.

I can see that SS_DATABASE_USERNAME and SS_DATABASE_PASSWORD are configured correctly from my __ss_environment.php file, but that don't seem to be enough. Is the _config.php executed when running silverstripe from the command line?
if not, how can I specify my database name and initialize my connection without duplicating my configuration that is already in _config.php

If someone has a bright idea, it would be great!