Add Salt in wp-config.php instead of wp-salt.php
At present when we add a new wordpress installation for all including the clean wordpress installtion. technically this will not affect the site however. when we use a security plugin it will be flagged. for example in Sucuri plugin it will be flagged as Core WordPress Files Were Modified. (this file flagged by all security plugin ). f someone delete it by mistake they will get 5xx error untill they fix it. to fix it they will have to add the file using SFTP. As this file can be deleted with wordpress security plugins like Sucuri

-
corey commented
Please change
require('wp-salt.php');
to
require(__DIR__.'/wp-salt.php');
as Tomas and the stack overflow post suggested.
wp-cli should just work without modifying wp-config. -
Tomas Mulder commented
This also causes issues when I try to use wp-cli from another host using the --ssh flag (for an automated GitLab CI script), since wp-cli isn't expecting this non-standard WordPress implementation and throws a PHP error. I think setting salts in wp-config.php is probably the best option, but even just adding __DIR__.'/wp-salt.php' would have solved my issue (see https://stackoverflow.com/a/75823827/483254). I'd prefer not to have to manually edit the wp-config.php any time I generate a fresh WordPress install on Cloudways in order for it to work with wp-cli from remote servers.