<p>I assume you've seen <a href="https://www.linode.com/docs/websites/apache/apache-web-server-on-ubuntu-14-04" rel="nofollow noreferrer">https://www.linode.com/docs/websites/apache/apache-web-server-on-ubuntu-14-04</a>?</p>

<p>Craft really isn't any different than any other PHP application in the way it needs to be setup to execute.  The only extra thing that other apps might not require (because most PHP apps don't auto-update) is that Craft needs to be able to recursively write to its <code>craft/app</code> folder in order for that to work.</p>

<p>There's a handy script here: <a href="https://github.com/nystudio107/craft-scripts" rel="nofollow noreferrer">https://github.com/nystudio107/craft-scripts</a> that can help automate the necessary permissions for your box, but you'll need still need to know what user:group Apache is running as for it to set things up properly.</p>

CC BY-SA 3.0
2017-02-01T20:07:04.140Z
Yeah cheers @bradbell I've used the linode docs but they don't really explain the owner/user set up on apache. They do say it uses the default web-data:web-data for php but setting these I still get an error say php can not write to the runtime folder unless I change it to 777 which isn't secure!
Lettie
CC BY-SA 3.0
2017-02-02T06:33:46.333Z
You try using that `craft-scripts` script with the user:group set to `web-data:web-data`?
Brad Bell
CC BY-SA 3.0
2017-02-04T15:29:45.647Z
Hi @bradbell I have now tried the scripts. They seem straight forward and worked in changing permissions but the site still does not work. I tried changing ownership to my local user but had the same write issues with php. Then tried changing both user and group to www-data and have an error service unavailable and now I can't change the owner back to my user so I can no longer ftp to the server! Command I'm using logged in as my user. sudo chown myUser:myUser /var/www/html/mysite.com/public_html but doing a ls -l shows the owner and group still as www-data. Any clues?
Lettie
CC BY-SA 3.0
2017-02-05T00:29:36.447Z
Try contacting Linode support? I'm really not that familiar with how they're setup.
Brad Bell
CC BY-SA 3.0
2017-02-07T13:17:47.087Z
Currently in a dialogue with Linode support.
Lettie
CC BY-SA 3.0
2017-01-31T18:46:59.557Z
2017-01-31T18:46:59.557Z
Brad Bell
<p>I'm setting up a Craft site on a Linode server has anyone had any experience with this? I'm struggling with which owner and user to set the <code>var/www/html</code> folder to with <code>chown</code> and what <code>chmod</code> settings to use on the craft folders. Currently Craft does not show the index page and can't find the admin folder which are all where they are supposed to be so it seems to be something to do with apache permissions. Just wondered if anyone could advise what these should be?</p>

CC BY-SA 3.0
2017-01-31T11:45:22.597Z
Try `set_perms.sh` from here: https://github.com/nystudio107/craft-scripts
Johannes
<server><permissions>
Setting up Craft on Linode Using Ubuntu
# Setting up Craft on Linode Using Ubuntu

(Asked by: username_0 on 2017-01-31)

I'm setting up a Craft site on a Linode server has anyone had any experience with this? I'm struggling with which owner and user to set the `var/www/html` folder to with `chown` and what `chmod` settings to use on the craft folders. Currently Craft does not show the index page and can't find the admin folder which are all where they are supposed to be so it seems to be something to do with apache permissions. Just wondered if anyone could advise what these should be?

**Tags:** server, permissions
> **Comments:**
> **username_1**: Try `set_perms.sh` from here: https://github.com/nystudio107/craft-scripts  

---

## 1 answers

### Answer by username_2 on 2017-01-31. Score: 1

I assume you've seen <https://www.linode.com/docs/websites/apache/apache-web-server-on-ubuntu-14-04>?

Craft really isn't any different than any other PHP application in the way it needs to be setup to execute. The only extra thing that other apps might not require (because most PHP apps don't auto-update) is that Craft needs to be able to recursively write to its `craft/app` folder in order for that to work.

There's a handy script here: <https://github.com/nystudio107/craft-scripts> that can help automate the necessary permissions for your box, but you'll need still need to know what user:group Apache is running as for it to set things up properly.

> **Comments:**
> **username_0**: Yeah cheers @bradbell I've used the linode docs but they don't really explain the owner/user set up on apache. They do say it uses the default web-data:web-data for php but setting these I still get an error say php can not write to the runtime folder unless I change it to 777 which isn't secure!  
> **username_2**: You try using that `craft-scripts` script with the user:group set to `web-data:web-data`?  
> **username_0**: Hi @bradbell I have now tried the scripts. They seem straight forward and worked in changing permissions but the site still does not work. I tried changing ownership to my local user but had the same write issues with php. Then tried changing both user and group to www-data and have an error service unavailable and now I can't change the owner back to my user so I can no longer ftp to the server! Command I'm using logged in as my user. sudo chown myUser:myUser /var/www/html/mysite.com/public_html but doing a ls -l shows the owner and group still as www-data. Any clues?  
> **username_2**: Try contacting Linode support? I'm really not that familiar with how they're setup.  
> **username_0**: Currently in a dialogue with Linode support.  

---

