Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes to monit template file are not deployed if an existing config file exists on the server #166

Closed
IanWhitney opened this issue Oct 27, 2016 · 0 comments · May be fixed by #193
Closed

Comments

@IanWhitney
Copy link

This task uploads the generated monit file to its home on the server.

As far as I can see, that task is only ever called from here, if the attempt to run monit monitor [service name] fails. Which it would do if the sidekiq/monit config file isn't present.

As a result, if there is a sidekiq/monit config file present, that task never fails and changes to the generated monit config file are never uploaded.

We're working around this by adding to our deploys

before :updating, 'sidekiq:monit:config'

So we're now always uploading the generated monit config, which is fine.

But is there a better way of handling this? Or a PR I can work on?

IanWhitney pushed a commit to umn-asr/capistrano-sidekiq that referenced this issue Feb 2, 2018
Fixes seuros#166

Because config was only called within the rescue block, changes to
config files would not be uploaded to servers on deployment.

Our fix is to always run config before monitoring. This means config
files will be uploaded every time that `monit:monitor` is run.
@seuros seuros closed this as completed Oct 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants