Is it possible to see console.log on the server in a deployed meteor site?


#1

I have a deployed .meteor.com site.

On this site I have a function I make using setInterval that modifies any old documents to the latest schema.

Basically, it looks like this and runs every 5 seconds.

Meteor.startup(function() {
return Meteor.setInterval(UpgradeToLatestVersion, 5000);
});

I have tested this on my local machine and it seems to be working.

However, when I deploy to my meteor.com instance, this UpgradeToLatestVersion does not seem to be running.

I don’t know if it’s not running at all or if it’s running and failing. The UpgradeToLatestVersion function has got lots of console.log statements which of course I can see on the local machine. Is it possible to somehow log in to the deployed meteor.com site and see any console.log outputs on the server?


#2

If it’s running on a meteor.com thing (meteor deploy blah.meteor.com), just use meteor logs site.meteor.com and it’ll give you a tail of the log.

It’s not realtime, but it’ll give you the last bit of the logs, anyway.


#3

Ah thanks that’s exactly what I was looking for.