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

WIP WIP WIP #139

Closed
wants to merge 6 commits into from
Closed

WIP WIP WIP #139

wants to merge 6 commits into from

Conversation

bochecha
Copy link
Contributor

@bochecha bochecha commented Aug 31, 2017

I'm about 75% confident that the commit in this branch related to uWSGI should fix https://framagit.org/ideascube/ideascube/issues/829.

This pull request only factorizes the handlers I found defined multiple times throughout the roles.

In general, it would probably be a good idea to define all the handlers at the top level, to avoid this kind of duplication in the future?

Mathieu Bridon added 6 commits August 31, 2017 18:14
Having it in each and every role means that Ansible considers them
separate handlers.

As a result, Nginx can be restarted more than once at the end of a
playbook.
Having it in each and every role means that Ansible considers them
separate handlers.

As a result, dnsmasq can be restarted more than once at the end of a
playbook.
Having it in each and every role means that Ansible considers them
separate handlers.

As a result, tinc can be restarted more than once at the end of a
playbook.
Having it in each and every role means that Ansible considers them
separate handlers.

As a result, tinc can be reloaded more than once at the end of a
playbook.
Having it in each and every role means that Ansible considers them
separate handlers.

As a result, uWSGI can be restarted more than once at the end of a
playbook.

When it starts, uWSGI runs the Ideascube app, which runs collectstatic.

Because the uWSGI service is `Type=forking`, systemd considers uWSGI
finished started when the parent process exits. But that happens long
before collectstatic finished running.

As a result, it is possible that Ansible will restart uWSGI twice in a
row, while the first one was still running collectstatic.

We think this is what could cause a weird Ideascube bug:

https://framagit.org/ideascube/ideascube/issues/829
If we were right about the fact that the Ideascube bug was created by
the multiple restarts of uWSGI (see previous commit), then this is now
unnecessary.
@bochecha
Copy link
Contributor Author

I'm about 75% confident that the commit in this branch related to uWSGI should fix https://framagit.org/ideascube/ideascube/issues/829.

And it seems I was wrong. 😞

ansible/ansible#4943

@bochecha
Copy link
Contributor Author

Closing this, because it's completely useless.

@bochecha bochecha closed this Aug 31, 2017
@bochecha bochecha deleted the handlers branch August 31, 2017 17:09
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 this pull request may close these issues.

None yet

1 participant