newbie question: how to get more than one user to be in the GROUP for directory ownership?

This is a discussion on newbie question: how to get more than one user to be in the GROUP for directory ownership? within the Redhat forums, part of the Linux category; I need "apache" and my username to share access to a directory because my php script creates directories within a directory. For example the directory /home/html/mysite/files, I want apache to ...

Go Back   Unix Linux Forum > Unix > Linux > Redhat

FixUnix.com - Unix Linux Forums

Unix Content Register FAQ Calendar Search Today's Posts Mark Forums Read
  #1  
Old 08-21-2008, 03:41 PM
Default newbie question: how to get more than one user to be in the GROUP for directory ownership?

I need "apache" and my username to share access to a directory because my
php script creates directories within a directory.

For example the directory /home/html/mysite/files, I want apache to be able
to create directories and file and I need to see those files and directories
when I use WinSCP using my username to login.

Currently, I did this and it allows the script to write directories:
chown username:apache files

I use WinSCP (which logs in using username) to check out what's inside those
directories and it errors out, permission denied.

Any ideas are much appreciated!


Reply With Quote
  #2  
Old 08-22-2008, 07:14 PM
Default Re: newbie question: how to get more than one user to be in theGROUP for directory ownership?

On Thu, 21 Aug 2008 15:41:52 -0400, TriAdmin wrote:

> I need "apache" and my username to share access to a directory because
> my php script creates directories within a directory.
>
> For example the directory /home/html/mysite/files, I want apache to be
> able to create directories and file and I need to see those files and
> directories when I use WinSCP using my username to login.
>
> Currently, I did this and it allows the script to write directories:
> chown username:apache files
>
> I use WinSCP (which logs in using username) to check out what's inside
> those directories and it errors out, permission denied.
>
> Any ideas are much appreciated!


If you are going to have the group as apache anyway, then just you could
just add your username to that group:

usermod -aG apache username

- NL
Reply With Quote
Reply

Thread Tools


All times are GMT -5. The time now is 01:12 PM.

In an effort to better serve ads to our visitors, cookies are used on Fixunix.com. For more information, check out our Privacy Policy.

Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
Ad Management by RedTyger