如何更改绑定安装点的命运所有者

如何更改绑定安装点的命运所有者
sudo mount -o user=www-data,group=www-data --bind /home/chachan/workspace/ /var/www
sudo mount -o owner=www-data,group=www-data --bind /home/chachan/workspace/ /var/www
chachan@magento:~$ sshfs [email protected]:/home/chachan/workspace/magento /home/chachan/workspace
chachan@magento:~$ sudo mount -o owner=www-data,group=www-data --bind /home/chachan/workspace/ /var/www
chachan@magento:~$ ls -lh /var/www
total 700K
-rw-r--r-- 1 chachan chachan 2.8K Nov 26 10:44 api.php
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 app
-rw-r--r-- 1 chachan chachan 2.8K Nov 26 10:44 cron.php
-rw-r--r-- 1 chachan chachan  717 Nov 26 10:44 cron.sh
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 downloader
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 errors
-rw-r--r-- 1 chachan chachan 1.2K Nov 26 10:44 favicon.ico
-rw-r--r-- 1 chachan chachan 5.9K Nov 26 10:44 get.php
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 includes
-rw-r--r-- 1 chachan chachan 2.6K Nov 26 10:44 index.php
-rw-r--r-- 1 chachan chachan 2.4K Nov 26 10:44 index.php.sample
-rw-r--r-- 1 chachan chachan 6.3K Nov 26 10:44 install.php
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 js
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 lib
-rw-r--r-- 1 chachan chachan  11K Nov 26 10:44 LICENSE_AFL.txt
-rw-r--r-- 1 chachan chachan  11K Nov 26 10:44 LICENSE.html
-rw-r--r-- 1 chachan chachan  11K Nov 26 10:44 LICENSE.txt
-rw-r--r-- 1 chachan chachan 1.3K Nov 26 10:44 mage
drwxr-xrwx 1 chachan chachan 4.0K Mar 31 09:33 media
-rw-r--r-- 1 chachan chachan  886 Nov 26 10:44 php.ini.sample
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 pkginfo
-rw-r--r-- 1 chachan chachan 572K Nov 26 10:44 RELEASE_NOTES.txt
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 shell
drwxr-xr-x 1 chachan chachan 4.0K Nov 26 10:44 skin
drwxr-xrwx 1 chachan chachan 4.0K Nov 26 10:44 var

我想www-data:www-data在上面的文件列表中将其作为所有者:组。

知道我遗漏了什么或者做错了什么吗?

谢谢

答案1

我修复了为 sshfs 添加uid和选项gidallow_another问题。如下所示:

sshfs -o uid=33,gid=33,allow_another [email protected]:/home/chachan/workspace/magento /home/chachan/workspace

我还添加了(取消注释)user_allow_other选项/etc/fuse.conf并且它运行顺利:)

相关内容