Skip to content

Commit

Permalink
fix: correct reference to Envoy Lua filters
Browse files Browse the repository at this point in the history
Not sure why the tests at
https://github.com/supabase/postgres/blob/ab7f879ba4bfacb4d0568c42f6d14c11826c8a03/testinfra/test_ami_nix.py#L343
didn't catch this, but can investigate that seperately.
  • Loading branch information
thebengeu committed Sep 11, 2024
1 parent ab7f879 commit 884e1c4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions ansible/files/envoy_config/lds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,7 @@ resources:
local path = request_handle:headers():get(":path")
request_handle
:headers()
:replace(":path", path:gsub("&=[^&]*", ""):gsub("?=[^&]*$", ""):gsub("?=[^&]*&", "?"))
:replace(":path", path:gsub("&apikey=[^&]*", ""):gsub("?apikey=[^&]*$", ""):gsub("?apikey=[^&]*&", "?"))
:replace(":path", path:gsub("&=[^&]*", ""):gsub("?=[^&]*$", ""):gsub("?=[^&]*&", "?"):gsub("&apikey=[^&]*", ""):gsub("?apikey=[^&]*$", ""):gsub("?apikey=[^&]*&", "?"))
end
remove_empty_key_query_parameters:
inline_string: |-
Expand All @@ -103,7 +102,6 @@ resources:
request_handle
:headers()
:replace(":path", path:gsub("&=[^&]*", ""):gsub("?=[^&]*$", ""):gsub("?=[^&]*&", "?"))
end
- name: envoy.filters.http.compressor.brotli
typed_config:
Expand Down Expand Up @@ -290,7 +288,7 @@ resources:
envoy.filters.http.lua:
'@type': >-
type.googleapis.com/envoy.extensions.filters.http.lua.v3.LuaPerRoute
name: remove_apikey_and_empty_key_query_parameter
name: remove_apikey_and_empty_key_query_parameters
- match:
prefix: /rest/v1/
request_headers_to_remove:
Expand All @@ -303,7 +301,7 @@ resources:
envoy.filters.http.lua:
'@type': >-
type.googleapis.com/envoy.extensions.filters.http.lua.v3.LuaPerRoute
name: remove_empty_key_query_parameter
name: remove_empty_key_query_parameters
- match:
prefix: /rest-admin/v1/
query_parameters:
Expand Down Expand Up @@ -414,3 +412,4 @@ resources:
filename: /etc/envoy/fullChain.pem
private_key:
filename: /etc/envoy/privKey.pem

2 changes: 1 addition & 1 deletion common-nix.vars.pkr.hcl
Original file line number Diff line number Diff line change
@@ -1 +1 @@
postgres-version = "15.6.1.120"
postgres-version = "15.6.1.121"

0 comments on commit 884e1c4

Please sign in to comment.