This PR fixes problem happens during second and further converge, trying to overwrite monit binary file while the file is already opened and not writable.
The binary install recipe now detects following 3 cases and behaves differently:
case 1) Binary file not found
the recipe download binary and installs it
case 2) Binary file found and different version need to be installed
the recipe delete the binary file as there is case it's running and not writable, and download and installs new one
case 3) Binary file found and same version as the one to be installed
skips download and installation
This PR fixes problem happens during second and further converge, trying to overwrite monit binary file while the file is already opened and not writable.
The binary install recipe now detects following 3 cases and behaves differently: case 1) Binary file not found the recipe download binary and installs it case 2) Binary file found and different version need to be installed the recipe delete the binary file as there is case it's running and not writable, and download and installs new one case 3) Binary file found and same version as the one to be installed skips download and installation