From 9020cc32a5764ae262ab361d14a1afc4a8914603 Mon Sep 17 00:00:00 2001 From: Paul Bonaud Date: Thu, 4 Apr 2019 12:21:12 +0200 Subject: dhall(fix): fix for generated configuration for Kong 1.x upgrade --- dhall/server/service/plugin/Config.dhall | 10 +++++----- dhall/server/service/plugin/mkRequestTransformer.dhall | 16 ++++++++-------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/dhall/server/service/plugin/Config.dhall b/dhall/server/service/plugin/Config.dhall index 73a333f..d54436b 100644 --- a/dhall/server/service/plugin/Config.dhall +++ b/dhall/server/service/plugin/Config.dhall @@ -1,9 +1,9 @@ < CorrelationId : - { header_name : Text, echo_downstream : Bool } + { header_name : Text, echo_downstream : Bool } | RequestTransformer : - { `add.headers` : Text } + { add : { headers : List Text } } | RequestTermination : - { status_code : Natural, content_type : Text, body : Text } + { status_code : Natural, content_type : Text, body : Text } | IPRestriction : - { whitelist : Text } -> + { whitelist : Text } +> \ No newline at end of file diff --git a/dhall/server/service/plugin/mkRequestTransformer.dhall b/dhall/server/service/plugin/mkRequestTransformer.dhall index 90789c8..1d8d608 100644 --- a/dhall/server/service/plugin/mkRequestTransformer.dhall +++ b/dhall/server/service/plugin/mkRequestTransformer.dhall @@ -1,11 +1,11 @@ - let Plugin = ./Plugin.dhall +let Plugin = ./Plugin.dhall in let config = constructors ./Config.dhall -in λ(header : Text) - → { name = - "request-transformer" - , config = - config.RequestTransformer { `add.headers` = header } - } - : Plugin + in λ(header : Text) + → { name = + "request-transformer" + , config = + config.RequestTransformer { add = { headers = [ header ] } } + } + : Plugin \ No newline at end of file -- cgit v1.2.3