title: CORS on Serverless yml
body: <p>I have a React application and trying to access to serverless from aws. But I have below error</p>
  
  <pre><code>No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://www.test.com' is therefore not allowed access. The response had HTTP status code 502.
  </code></pre>
  
  <p>End point url is <a href="https://key.execute-api.ap-southeast-2.amazonaws.com/dev/samplefunction" rel="noreferrer">https://key.execute-api.ap-southeast-2.amazonaws.com/dev/samplefunction</a></p>
  
  <p>Setting on serverless.yml is</p>
  
  <pre><code>login:
      handler: login.login
      events:
        - http:
            path: login
            method: post
            cors:
              origin: 'https://admin.differentdomain.com'
              headers:
                - MY_CUSTOM_HEADER
                - Content-Type
                - X-Amz-Date
                - Authorization
                - X-Api-Key
                - X-Amz-Security-Token
  </code></pre>
  
  <p>Is there any other place I need to do CORS configuration?</p>