config: fix France Connect callback URL when testing locally

When testing France Connect on a local development environment, the
callback URL should be something like `http://localhost:3000/…/…`

But currently, the callback URL uses `https`, even in development. This
causes the callback URL to be rejected by France Connect.

This commit overrides the callback URL when in development, to use
an `http` URL instead. In doesn't affect the production settings.
This commit is contained in:
Pierre de La Morinerie 2020-01-08 10:42:31 +00:00
parent cfdaa95c0c
commit f04fb3830c

View file

@ -15,7 +15,7 @@ defaults: &defaults
basic_auth:
username: <%= ENV['BASIC_AUTH_USERNAME'] %>
password: <%= ENV['BASIC_AUTH_PASSWORD'] %>
france_connect_particulier:
france_connect_particulier: &france_connect_particulier
identifier: <%= ENV['FC_PARTICULIER_ID'] %>
secret: <%= ENV['FC_PARTICULIER_SECRET'] %>
redirect_uri: https://<%= ENV['APP_HOST'] %>/france_connect/particulier/callback
@ -76,6 +76,10 @@ defaults: &defaults
development:
<<: *defaults
france_connect_particulier:
<<: *france_connect_particulier
redirect_uri: http://<%= ENV['APP_HOST'] %>/france_connect/particulier/callback
test:
<<: *defaults