2013-12-23

Twitter automation

Some time ago I wrote a post about twitter from the Data Warehouse. I actually have had some problems with the twitter, I failed to run it via Cron and I didn’t have the time or interest to analyze the problem. But yesterday I did. It is almost always a problem with the ‘env’ when you can run a process in the normal shell but not from Cron, so I var_dump(system(‘env’)) in my PHP script and compared and sure enough, the Cron environment missed a proxy definition. So this morning the first truly automatic tweed was heard from the Data Warehouse, which you can follow on https://twitter.com/@tooljn for the time beeing, we should probably find a better name for it.
Here is the process scheduled by Cron:


There is a problem with this tweet, the number of mysql queries are from the day before. I take the status from Mysql at 17:30 when the backup is run with this shell script:

So the query figure in the tweet is a bit unsynchronized, but who cares :)

No comments:

Post a Comment