LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-25-2014, 09:14 AM   #1
alain.roger
LQ Newbie
 
Registered: Mar 2014
Posts: 2

Rep: Reputation: Disabled
Question directory and file permissions


Hi,

under fedora 20 i would like to setup a webserver for testing purposes.
everything is ok and /var/www/html is the directory where all websites should be stored and developed.

1. however with one of my friend we would like to work together from 2 different computers, so as /var/www/html is owned by root:root, what is the best method to allow both of us (let's say "dev1", "dev2" fedora accounts) to create, modify, delete files and directories in this web root (/var/www/html) ?

2. should i create a group and add those 2 accounts into it ?

thx.

A.
 
Old 03-25-2014, 09:23 AM   #2
kkoene
Member
 
Registered: May 2008
Location: Wisconsin
Distribution: Fedora, Ubuntu, RHEL, AIX6
Posts: 33

Rep: Reputation: 0
#2 is how I would go about working the issue. Setup a group called something like devgrp (original..I know...) and put both accounts into it.
 
Old 03-25-2014, 05:02 PM   #3
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,912

Rep: Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513Reputation: 1513
It really depends on what you are trying to do.

You could even use the public_dir entry and provide the files from within your home directory.

The advantage is ease of editing and testing things. When finished, the files could then be moved to somewhere more permanent.
 
Old 03-25-2014, 05:15 PM   #4
joe_2000
Senior Member
 
Registered: Jul 2012
Location: Aachen, Germany
Distribution: Void, Debian
Posts: 1,016

Rep: Reputation: 308Reputation: 308Reputation: 308Reputation: 308
I personally bind-mount the project dir in my home to /var/www for testing purposes on my local computer. (In your case that would be any sensible shared directory you both have access to.)
In combination with that I am closing port 80 by iptables to be on the safe side...

Works very nicely...
 
Old 03-25-2014, 08:54 PM   #5
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Quote:
Originally Posted by kkoene View Post
#2 is how I would go about working the issue. Setup a group called something like devgrp (original..I know...) and put both accounts into it.
Insufficient. They'd have to chown the /var/www/html to "apply" the devgrp to it.
make backups of /var/www/html first and you could:
Code:
chown -R root:devgrp /var/www/html/*
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
file/directory permissions mianmajidali Linux - Server 1 10-08-2009 10:35 AM
File permissions v. directory permissions Completely Clueless Linux - Newbie 7 07-09-2009 08:33 AM
File/Directory Permissions waynevnc Debian 1 05-23-2005 04:23 PM
File and Directory permissions plasmapudding Red Hat 3 09-09-2003 10:26 AM
Directory and file permissions ryan Linux - Security 2 12-06-2000 12:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:35 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration