title: Spring boot with YAML, CORS doesn't work
body: <p>is it possible to create YAML config to handle CORS? I use gradle and spring boot ver 1.5.4.
  this is my YML file and it doesn't work:</p>
  
  <pre><code> endpoints:
    cors:
      allowed-methods: '*'
      allowed-origins: '*'
  </code></pre>
  
  <p>build.gradle:</p>
  
  <pre><code>buildscript {
      ext {
         springBootVersion = '1.5.4.RELEASE'
      }
      repositories {
         jcenter()
      }
      dependencies {
          classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
      }
  }
  
  apply plugin: 'java'
  apply plugin: 'eclipse-wtp'
  apply plugin: 'org.springframework.boot'
  apply plugin: 'war'
  
  version = '0.0.1-SNAPSHOT'
  sourceCompatibility = 1.8
  targetCompatibility = 1.8
  
  repositories {
      jcenter()
  }
  
  configurations {
      providedRuntime
  }
  
  dependencies {
      compile('org.springframework.boot:spring-boot-starter-actuator')
      compile('org.springframework.boot:spring-boot-starter-data-elasticsearch')
      compile('org.springframework.boot:spring-boot-starter-data-jpa')
      compile('org.springframework.boot:spring-boot-starter-freemarker')
      compile('org.springframework.boot:spring-boot-starter-mail')
      compile('org.springframework.boot:spring-boot-starter-web')
      runtime('mysql:mysql-connector-java')
      compileOnly('org.projectlombok:lombok')
      providedRuntime('org.springframework.boot:spring-boot-starter-tomcat')
      testCompile('org.springframework.boot:spring-boot-starter-test')
  }
  </code></pre>
  
  <p>Anyone have idea what is wrong? thanks in advance for help</p>