This script makes some occ commands available to environments where you don’t have shell access (i. e. hosted environments).
I don’t think this is very safe. It might corrupt your database when PHP times
out on longer operations.
On small installations like mine, however it works
just fine.
First generate a user password pair. For that, hash your password using the hash_password function.
E. g. like this:
<?php
echo password_hash("yourpassword", PASSWORD_DEFAULT);
?>
This will generate a hash of your password so you don’t have to store it on the
server.
Now copy the hash into cli-config-example.php
and rename it to
cli-config.php
.
Now copy cli.php
and cli-config.php
to the root directory of
your nextcloud installation.
https://www.your-cloud.tld/cli.php