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

Use order from /etc/rc.d when doing service reloads/restarts #23

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

okraits
Copy link
Contributor

@okraits okraits commented May 9, 2016

So far, the services restart order when running easycwmp apply service is rather random and doesn't comply with the order defined in /etc/rc.d. This commit fixes that.

@pivasoftware
Copy link
Owner

pivasoftware commented May 10, 2016

For OpenWRT system, the restart of service is done by the function common_uci_track_restart_services(). This function determine automatically the service to restart in OpenWRT. So the "apply_service_tmp_file" is useless for OpenWRT. You should get an empty file.

If you are working with "apply_service_tmp_file" that means that you called (in your data model) the functions:
common_delay_service_restart_in_apply_service() or common_execute_command_in_apply_service()

If you are working with OpenWRT, So you have to refer to the function common_uci_track_restart_services() and change it in order to restart services in order

@pivasoftware
Copy link
Owner

Beside that, Your change has to take account that the "$apply_service_tmp_file" does not contains only services to restart. It could contains also commands. So your changes will skip all commands in the "$apply_service_tmp_file" file

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.

2 participants