title: Zend Framework 2 How To Set Doctrine 2 Proxy Directory
body: <p>So I am using Doctrine 2 module in Zend Framework 2 configured according to Jason Grimes' turorial (<a href="http://www.jasongrimes.org/2012/01/using-doctrine-2-in-zend-framework-2/" rel="nofollow noreferrer">http://www.jasongrimes.org/2012/01/using-doctrine-2-in-zend-framework-2/</a>).</p>
  <p>Sometimes I keep getting this error though:</p>
  <blockquote>
  <p>Your proxy directory must be writable.</p>
  </blockquote>
  <p>How can I set the proxy directory?</p>
  <p>Here is my Doctrine configuration from <code>module.config.php</code>:</p>
  <pre><code>'doctrine' =&gt; array(
      'driver' =&gt; array(
          __NAMESPACE__ . '_driver' =&gt; array(
              'class' =&gt; 'Doctrine\ORM\Mapping\Driver\AnnotationDriver',
              'cache' =&gt; 'array',
              'paths' =&gt; array(__DIR__ . '/../src/' . __NAMESPACE__ . '/Entity')
          ),
          'orm_default' =&gt; array(
              'drivers' =&gt; array(
                  __NAMESPACE__ . '\Entity' =&gt; __NAMESPACE__ . '_driver'
              ),
          ),
      ),
  ),
  </code></pre>