Thanks for the answer but I am still confused. Which scripts will ever be needed to run from cli? Are those scripts (that must be run from command line), required to run (start, stop, config) the server or are scripts that run from a page inside site, thus can safely use server's php?
If they are required by extensions in order to be installed or to run some kind of modifications or for parametrization (outside of the webserver, from command line) then this is an extension's requirement and should be extension's reliability to check if it is safe to run.
Is it sure that there is nothing to worry having a version of php inside server (ex. Apache) and use a second version of php to run (from inside or outside Apache) any script that affects mediawiki site (even if compatible)?