Mac OSX上的Apache写权限 [英] Mac OSX Apache Write Privileges

查看:746
本文介绍了Mac OSX上的Apache写权限的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

因此​​,这里是我的问题。它开始时,我发现我无法从管理面板安装在Word preSS插件或主题,它只是不停的问我的连接信息(的 http://cl.ly/DLdH/o )。

So here is my problem. Its started when I discovered that I couldn't install plugins or themes in WordPress from the admin panel, it just kept asking for my connection info ( http://cl.ly/DLdH/o ).

我发现了一个博客张贴这表明改变字preSS文件夹的所有权给Apache用户,即_www像这样

I found a blog post which suggested changing the ownership of the wordpress folder to the Apache user, i.e. _www like so

sudo chown -R _www ./

这做,部分地解决这个问题,因为我是能够安装插件和主题以及写PHP通过目录这是所有好的,但后来我不能添加/删除/编辑的任何文件在我文本编辑器,甚至在Finder中。它只是不断以处理动作要求我的用户密码。

That did, partially, fix the problem as I was able to install plugins and themes as well as writing to the directory through PHP which was all good but then I couldn't add/delete/edit any of the files in my text editor or even in Finder. It just keeps asking for my user password in order to process the action.

更改所有权回修复密码的问题,但后来我不能做任何书面文件的目录,虽然PHP了。

Changing the ownership back fixes the password issue but then I cant do any writing to the directory though PHP anymore.

有没有一种方法可以让我做的两个的事情在同一时间?

Is there a way to allow me do both things at the same time?

编辑:

我碰到这个CMD来到

sudo dscl . -append /Groups/_www GroupMembership [myUsername]

里面加了我,即我的用户名到组_www,然后我执行

which added me i.e. my username to the group _www, then I executed

sudo chown -R _www .
sudo chgrp -R _www .

那么它的工作!

推荐答案

拥有的用户的自己的文件。更改的集团 _www 。给写权限组。

Have the user own the files. Change the group to _www. Give write permission to group.

chown -R <username> .
chgrp -R _www .
chmod -R g+w .

这篇关于Mac OSX上的Apache写权限的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆