jamesrwhite / minicron

🕰️ Monitor your cron jobs
GNU General Public License v3.0
2.34k stars 154 forks source link

Recommended setting of config file #161

Closed robinjoseph08 closed 8 years ago

robinjoseph08 commented 8 years ago

Hey @jamesrwhite,

I see that you removed the default config location of /etc/minicron.toml. Because there's not a default location, I was wondering how you'd recommend setting configs for a cron client.

Here's my setup: I have one server that acts as my minicron server (hosts the hub and the DB) and another server that is my actual cron worker. Since this isn't the usual setup of everything running on the same server, I've got a few custom configs to set for both client and server (for example, client.server.host isn't 0.0.0.0 anymore).

For the server, I can easily run minicron server stop --config /path/to/config.toml when I start the hub (though it isn't the most convenient), but for the client that runs minicron run, as far as I can tell, I can't specify the config file to use since it's the hub that writes the minicron run command to /etc/crontab.

Was there an explicit reason you removed the default config file? It seems to have just made things a little more complicated to work with :/ Am I missing something?

jamesrwhite commented 8 years ago

Hmmm yeah, this may have been a slight oversight on my part. It was messing with the tests a bit so I was being lazy and thought I could remove it. I'll probably revert that change tomorrow and come up with a better solution for my test issue, thanks for pointing this out!

robinjoseph08 commented 8 years ago

Awesome, thanks for the quick response! This is a great project and I can't wait til it sees v1.0.0!

jamesrwhite commented 8 years ago

https://github.com/jamesrwhite/minicron/releases/tag/v0.8.2 🎉

robinjoseph08 commented 8 years ago

https://github.com/jamesrwhite/minicron/blob/b202a0f22143e43549592fdeefd3212e17f9e6c2/lib/minicron/cli.rb#L24

The if opts.config needs to be removed also :(

jamesrwhite commented 8 years ago

image

jamesrwhite commented 8 years ago

https://github.com/jamesrwhite/minicron/releases/tag/v0.8.3

Thanks for your help with this.