Added occ script.
This commit is contained in:
14
occ-from-anywhere/occ
Normal file
14
occ-from-anywhere/occ
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
## Make this file executable and save it as /usr/bin/occ
|
||||||
|
## Now whenever you want to use the CLI tool occ, you can
|
||||||
|
## do it from anywhere.
|
||||||
|
|
||||||
|
nextcloudpath="/var/www/html"
|
||||||
|
wwwuser="www-data"
|
||||||
|
|
||||||
|
|
||||||
|
sudo -u $wwwuser php "$nextcloudpath/occ" $@
|
||||||
|
errorcode=$?
|
||||||
|
exit $errorcode
|
||||||
|
|
||||||
Reference in New Issue
Block a user