Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Beginning Joomla on Ubuntu

Posted on 2011-09-12
3
Medium Priority
?
366 Views
Last Modified: 2012-05-12
I've decided to learn Joomla and I setup an ubuntu environment as a test bed.  I was able to get the basics working.  I am struggling with file permissions.  

I log onto my ubuntu machine as user 'myUser/.  But all the web stuff goes under /var/www  

In order to edit a file i have to 'sudo vi'  or 'chown myUser'.   I eventually got tired of that and did a 'sudo chmod -R 777 /var/www' .  This shotgun method worked, but I can't imaging its good practice.    

How do I setup myUser to edit /var/www for easy editing and still maintain some decent security?

0
Comment
Question by:tmonteit
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 6

Accepted Solution

by:
yjchong514 earned 1000 total points
ID: 36527196
chmod 744 for your user.
Refer: http://www.december.com/unix/ref/chmod.html for command tutorial.

To start your login with /var/www:
1.Adding your user to /var/www:
sudo useradd your_user -p your_password -d /var/www -s /bin/false
sudo passwd your_user

2. change the directory specifications in the /etc/proftpd/proftpd.conf file
E.g:
...
<Directory /var/www>
Umask 022 022
AllowOverwrite off
        <Limit DELE XMKD RNRF RNTO RMD XRMD>
        DenyAll
        </Limit>
        <Limit MKD STOR>
        AllowAll
        </Limit>
</Directory>
.....

Good Luck!

Rgds,

yjchong514
0
 

Author Comment

by:tmonteit
ID: 36527293
Confused... /var/www is the directory of all my web stuff and I can't log in as /var/www.

When I try that command, it says:   useradd:  your_user already exists.

0
 
LVL 4

Assisted Solution

by:undersky
undersky earned 1000 total points
ID: 36527524
you can simply add self to www-data group :)

sudo adduser uruser www-data

also chmod 775 /var/www/ -R
sudo /etc/init.d/apache2 restart
0

Featured Post

Fill in the form and get your FREE NFR key NOW!

Veeam® is happy to provide a FREE NFR server license to certified engineers, trainers, and bloggers.  It allows for the non‑production use of Veeam Agent for Microsoft Windows. This license is valid for five workstations and two servers.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
Fine Tune your automatic Updates for Ubuntu / Debian
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
Suggested Courses

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question