From 6f7035e4cf67121f511acd1b2276ab7858dbb9da Mon Sep 17 00:00:00 2001 From: Kevin Papst Date: Sat, 23 Mar 2019 13:24:15 +0100 Subject: [PATCH] fixing default env var for cors header (#656) --- config/packages/nelmio_cors.yaml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/config/packages/nelmio_cors.yaml b/config/packages/nelmio_cors.yaml index 15092e22..298ae4c9 100644 --- a/config/packages/nelmio_cors.yaml +++ b/config/packages/nelmio_cors.yaml @@ -1,15 +1,19 @@ +parameters: + env(CORS_ALLOW_ORIGIN): 'localhost' + nelmio_cors: defaults: allow_credentials: false - allow_origin: ['%env(CORS_ALLOW_ORIGIN)%'] - allow_headers: [] +# allow_origin: ['%env(CORS_ALLOW_ORIGIN)%'] # allow_headers: ['Content-Type', 'Authorization', 'X-AUTH-USER', 'X-AUTH-TOKEN'] - allow_methods: [] # allow_methods: ['GET', 'OPTIONS', 'POST', 'PUT', 'PATCH', 'DELETE'] - expose_headers: [] # expose_headers: ['Link'] - max_age: 0 # max_age: 3600 + allow_origin: [] + allow_headers: [] + allow_methods: [] + expose_headers: [] + max_age: 0 hosts: [] origin_regex: true forced_allow_origin_value: ~