Answers.Body: <p>The problem here was the URL in the database was wrong. I had assumed that config was entirely file-based but it seems that the config file is dependent upon the database Site URL. It would be great if this could be avoided as it makes deployment between environments so much easier without paths or URLs in the DB.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-10-28T19:56:02.273Z
Answers.LastActivityDate: 2014-10-28T19:56:02.273Z
Answers.UserDisplayName: Russ Back
Body: <p>Just deployed to a server which has the following open_basedir setting:</p>
  
  <pre><code>{DOCROOT}/:/usr/tmp:/var/www/vhosts/mydomain.com/httpdocs/
  </code></pre>
  
  <p>The webroot is at </p>
  
  <pre><code>/var/www/vhosts/mydomain.com/httpdocs/public_html
  </code></pre>
  
  <p>and craft is at</p>
  
  <pre><code>/var/www/vhosts/mydomain.com/httpdocs/craft
  </code></pre>
  
  <p>So all standard however I'm still getting this:</p>
  
  <blockquote>
    <p>Could not find your craft/ folder. Please ensure that $craftPath is set correctly in /var/www/vhosts/domain.com/httpdocs/public_html/index.php</p>
  </blockquote>
  
  <p>Any suggestions please?</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-10-23T21:33:34.577Z
Comments.Text: You sure it's an open_basedir problem and not a permissions one?  What are the perms on the craft folder?
Comments.UserDisplayName: Brad Bell
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-10-23T21:42:16.607Z
Comments.Text: I've tried 777 and set the right owner. Switching from Apache to CGI or FastCGI works but then I am unable to upload assets as I get a 500 on the ajax upload and nothing in the logs (this is on a Plesk/CentOS box)
Comments.UserDisplayName: Russ Back
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-10-23T22:20:58.387Z
Comments.Text: Did you check the Apache logs and the Craft logs (craft/storage/runtime/logs)?
Comments.UserDisplayName: Brad Bell
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-10-24T10:22:21.910Z
Comments.Text: Nothing in Craft logs, will check Apache. Interestingly, the URL in the control panel on the site name (top left) links to the domain defined in local config, not live, even though the domain config looks correct. The upload destination uses basePath and baseUrl from environmentVariables in config so perhaps that's it?
Comments.UserDisplayName: Russ Back
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-10-24T12:07:27.300Z
Comments.Text: Original problem solved - I had assumed that the config environment variables matched the server URL to config, but seems it is reliant on the siteUrl in the database? I now can't upload - saying files are empty. All PHP settings for uploads, sizes, post size etc should be fine, is there anything else we should be looking for?
Comments.UserDisplayName: Russ Back
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2014-10-24T17:07:40.350Z
Comments.Text: I'm not sure I'm following... probably worth adding an official answer to this one and starting a new question with more details on what you're seeing.
Comments.UserDisplayName: Brad Bell
Tags: <config>
Title: Problem with open_basedir?
ThreadText: # Problem with open_basedir?
  
  (Asked by: username_0 on 2014-10-23)
  
  Just deployed to a server which has the following open\_basedir setting:
  
  ```
  {DOCROOT}/:/usr/tmp:/var/www/vhosts/mydomain.com/httpdocs/
  
  ```
  
  The webroot is at
  
  ```
  /var/www/vhosts/mydomain.com/httpdocs/public_html
  
  ```
  
  and craft is at
  
  ```
  /var/www/vhosts/mydomain.com/httpdocs/craft
  
  ```
  
  So all standard however I'm still getting this:
  
  > Could not find your craft/ folder. Please ensure that $craftPath is set correctly in /var/www/vhosts/domain.com/httpdocs/public\_html/index.php
  
  Any suggestions please?
  
  **Tags:** config
  
  > **Comments:**
  > **username_1**: You sure it's an open_basedir problem and not a permissions one?  What are the perms on the craft folder?  
  > **username_0**: I've tried 777 and set the right owner. Switching from Apache to CGI or FastCGI works but then I am unable to upload assets as I get a 500 on the ajax upload and nothing in the logs (this is on a Plesk/CentOS box)  
  > **username_1**: Did you check the Apache logs and the Craft logs (craft/storage/runtime/logs)?  
  > **username_0**: Nothing in Craft logs, will check Apache. Interestingly, the URL in the control panel on the site name (top left) links to the domain defined in local config, not live, even though the domain config looks correct. The upload destination uses basePath and baseUrl from environmentVariables in config so perhaps that's it?  
  > **username_0**: Original problem solved - I had assumed that the config environment variables matched the server URL to config, but seems it is reliant on the siteUrl in the database? I now can't upload - saying files are empty. All PHP settings for uploads, sizes, post size etc should be fine, is there anything else we should be looking for?  
  > **username_1**: I'm not sure I'm following... probably worth adding an official answer to this one and starting a new question with more details on what you're seeing.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2014-10-28. Score: 1 | Accepted answer
  
  The problem here was the URL in the database was wrong. I had assumed that config was entirely file-based but it seems that the config file is dependent upon the database Site URL. It would be great if this could be avoided as it makes deployment between environments so much easier without paths or URLs in the DB.
  
  
  ---
  
  