title: How to add cors to nginx in elasticbeanstalk?
body: <p>I spent days now in researching on how to add some headers to nginx. All I try to do is adding these lines:</p>
  
  <pre><code>location ~ ^/(assets)/  {
    add_header Access-Control-Allow-Origin *;
  }
  </code></pre>
  
  <p>What is the best way to put these lines into the nginx.conf?
  Is there also a way to not overwrite the standard nginx.conf just in case beanstalk updates the settings so I wont miss it?</p>