Answers.Body: <p>I was performing all actions as a root. That was probably the reason no .conf file was generated in <em>/root/.amp/apache.d/</em>. I switched to a non-root user with sudo privileges and it worked smoothly.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-05-02T09:00:23.393Z
Answers.LastActivityDate: 2016-05-02T09:00:23.393Z
Answers.UserDisplayName: Dilip Raj Baral
Body: <p>I am trying to setup buildkit in my new Debian machine. I installed all the required packaged, ran <code>civi-download-tools</code> and <code>amp config</code> with correct credentials and included <code>Include /root/.amp/apache.d/*.con</code> in <em>apache2.conf</em> file. On restarting apache it gave me error saying there was no *.conf file to be included in <code>/root/.amp/apache.d</code>. I checked the directory; <strong>it was empty.</strong> </p>
  
  <p>However, I copied <code>localhost-7979.conf</code> from my previous buildkit setup on another machine and placed inside <code>/root/.amp/apache.d</code> folder and restarted apache. On running <code>amp test</code> it gave me following error:</p>
  
  <pre><code>PHP Warning:  file_get_contents(http://localhost:7979/index.php): failed to open stream: HTTP request failed! HTTP/1.1 403 Forbidden  in phar:///opt/buildkit/bin/amp/src/Amp/Command/TestCommand.php on line 163
  </code></pre>
  
  <p>I checked <code>localhost-7979-error.log</code> inside <code>root/.amp/log</code>. Following line was there.</p>
  
  <pre><code>'/root/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable and that '/root/' is executable'
  </code></pre>
  
  <p>Strange. There isn't even any <em>.htaccess</em> file inside <code>/root</code>.
  I tried every solution I could find on CiviCRM StackExchange and Forums but none worked.</p>
  
Tags: <civicrm-buildkit>
Title: Buildkit - amp test failed - /root/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable and that '/root/' is executable'
ThreadText: # Buildkit - amp test failed - /root/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable and that '/root/' is executable'
  
  (Asked by: username_0 on 2016-05-01)
  
  I am trying to setup buildkit in my new Debian machine. I installed all the required packaged, ran civi-download-tools and amp config with correct credentials and included Include /root/.amp/apache.d/*.con in apache2.conf file. On restarting apache it gave me error saying there was no *.conf file to be included in /root/.amp/apache.d. I checked the directory; it was empty. 
  However, I copied localhost-7979.conf from my previous buildkit setup on another machine and placed inside /root/.amp/apache.d folder and restarted apache. On running amp test it gave me following error:
  PHP Warning:  file_get_contents(http://localhost:7979/index.php): failed to open stream: HTTP request failed! HTTP/1.1 403 Forbidden  in phar:///opt/buildkit/bin/amp/src/Amp/Command/TestCommand.php on line 163
  
  I checked localhost-7979-error.log inside root/.amp/log. Following line was there.
  '/root/.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable and that '/root/' is executable'
  
  Strange. There isn't even any .htaccess file inside /root.
  I tried every solution I could find on CiviCRM StackExchange and Forums but none worked.
  
  **Tags:** civicrm-buildkit
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2016-05-02. Score: 1
  
  I was performing all actions as a root. That was probably the reason no .conf file was generated in */root/.amp/apache.d/*. I switched to a non-root user with sudo privileges and it worked smoothly.
  
  
  ---
  
  