Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ENVOY] feat: Envoy to set Service ID header from subdomain #102

Merged
merged 84 commits into from
Dec 19, 2024
Merged
Show file tree
Hide file tree
Changes from 77 commits
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
78e6fc1
feat: allow external auth server endpoint ID passing method to be con…
commoddity Dec 12, 2024
2f163b0
fix: configure envoy template to allow /v1 and /v1/
commoddity Dec 12, 2024
72ec291
chore: update TODO comment in auth handler
commoddity Dec 12, 2024
0b4f183
chore: remove envoy.yaml example file
commoddity Dec 13, 2024
71536be
Apply suggestions from code review
commoddity Dec 13, 2024
e5a12fa
chore: review comments and update docs
commoddity Dec 13, 2024
10de0a2
Merge branch 'main' of github.com:buildwithgrove/path into configurab…
commoddity Dec 13, 2024
e8a7689
Support using HTTP Headers to specify target service ID
adshmh Dec 13, 2024
8f9aa60
Merge branch 'feat-allow-service-alias-http-header' of github.com:bui…
commoddity Dec 13, 2024
043bb8e
fix: add lua filter to envoy template to allow setting service id hea…
commoddity Dec 13, 2024
b1ba9c1
chore: merge conflicts
commoddity Dec 13, 2024
ff20b40
chore: merge conflicts
commoddity Dec 13, 2024
9c532a5
Merge branch 'configurable-endpoint-id-passing' into envoy-set-header…
commoddity Dec 13, 2024
8fcea33
Merge branch 'main' into configurable-endpoint-id-passing
commoddity Dec 13, 2024
082d250
Merge branch 'main' into envoy-set-header-from-subdomain
commoddity Dec 13, 2024
023d44f
Merge branch 'configurable-endpoint-id-passing' into envoy-set-header…
commoddity Dec 13, 2024
ae4255e
chore: add lua to list of HTTP filters in docs
commoddity Dec 13, 2024
ca0eb98
chore: remove debug log
commoddity Dec 16, 2024
0a605ff
xMerge branch 'main' of github.com:buildwithgrove/path into configura…
commoddity Dec 16, 2024
7ac3532
Apply suggestions from code review
commoddity Dec 16, 2024
daca4d7
Merge branch 'configurable-endpoint-id-passing' of github.com:buildwi…
commoddity Dec 16, 2024
1699f44
fix: implement review comments
commoddity Dec 16, 2024
1c89f0e
chore: merge conflicts
commoddity Dec 16, 2024
6db9f68
chore: merge conflicts
commoddity Dec 16, 2024
69e429e
chore: merge conflicts
commoddity Dec 17, 2024
3b0e595
chore: merge conflicts
commoddity Dec 17, 2024
f25f8ae
chore: fix typo
commoddity Dec 17, 2024
c1d94d4
chore: remove refs to x- headers
commoddity Dec 17, 2024
0d326b5
chore: remove numbers from docusaurus internal links
commoddity Dec 17, 2024
0116e65
chore: merge conflicts
commoddity Dec 17, 2024
5c7043b
chore: modify script to handle setting of lua http filter
commoddity Dec 17, 2024
c1a31f9
chore: update docusarus docs about service id specification method
commoddity Dec 17, 2024
cd61b2f
chore: improve init scripts
commoddity Dec 17, 2024
1698a79
chore: add example request for all headers
commoddity Dec 17, 2024
d8a4595
chore: set default in ext_authz k8s file to url_path
commoddity Dec 17, 2024
0b15e1d
chore: set default in ext_authz k8s file to url_path
commoddity Dec 17, 2024
3b3f78b
Merge branch 'envoy-set-header-from-subdomain' of github.com:buildwit…
commoddity Dec 17, 2024
94e016a
feat: add allowed-services file for handling which services are allow…
commoddity Dec 17, 2024
ba159fd
chore: add morse chains and simple aliases to allowed services templa…
commoddity Dec 17, 2024
878fa1b
chore: add morse chains and simple aliases to allowed services templa…
commoddity Dec 17, 2024
a1c925d
Merge branch 'envoy-set-header-from-subdomain' of github.com:buildwit…
commoddity Dec 17, 2024
941c367
Merge branch 'envoy-set-header-from-subdomain' of github.com:buildwit…
commoddity Dec 17, 2024
2838ede
Merge branch 'envoy-set-header-from-subdomain' of github.com:buildwit…
commoddity Dec 17, 2024
d5e6a1c
fix: syntax in .lua template file
commoddity Dec 17, 2024
1b41827
fix: syntax in .lua template file
commoddity Dec 17, 2024
18711bc
chore: merge conflicts
commoddity Dec 17, 2024
a6277d6
fix: use global variable in lua filter
commoddity Dec 17, 2024
ca0ea8c
fix: morse e2e test
commoddity Dec 17, 2024
acdeda1
Followup to #103
Olshansk Dec 18, 2024
309fa72
Adding some helpers for makefile test helpers
Olshansk Dec 18, 2024
4d9d6e9
Link to 1Password UUIDs
Olshansk Dec 18, 2024
94eeac2
Remove gatewaye2e
Olshansk Dec 18, 2024
309b40e
Remove ServiceIDE2E
Olshansk Dec 18, 2024
dedd5ee
Merge branch 'main' into envoy-set-header-from-subdomain
Olshansk Dec 18, 2024
3c6890f
chore: add envoy config doc
commoddity Dec 18, 2024
c825b24
Merge branch 'envoy-set-header-from-subdomain' of github.com:buildwit…
commoddity Dec 18, 2024
ae334ca
Merge branch 'envoy-set-header-from-subdomain' of github.com:buildwit…
commoddity Dec 18, 2024
90c92e6
Merge branch 'envoy-set-header-from-subdomain' of github.com:buildwit…
commoddity Dec 18, 2024
a8a4391
fix: link in docs
commoddity Dec 18, 2024
cb5b24f
fix: small changes to fix morse E2E test
commoddity Dec 18, 2024
381270b
Remove .allowed-service.lua from the repository
commoddity Dec 18, 2024
9917603
Remove .allowed-service.lua from the repository
commoddity Dec 18, 2024
7ac79d1
Merge branch 'add-all-morse-services-follow-up' of github.com:buildwi…
commoddity Dec 18, 2024
16f6327
Merge branch 'fix-morse-e2e' of github.com:buildwithgrove/path into f…
commoddity Dec 18, 2024
711ea12
Merge branch 'main' of github.com:buildwithgrove/path into add-all-mo…
commoddity Dec 18, 2024
5426ce3
Merge branch 'add-all-morse-services-follow-up' of github.com:buildwi…
commoddity Dec 18, 2024
052232d
chore: merge conflicts
commoddity Dec 18, 2024
ce374ec
Merge branch 'main' into fix-morse-e2e
commoddity Dec 18, 2024
660d6ce
chore: remove deprecated 0021 alias
commoddity Dec 18, 2024
1c180e3
Merge branch 'fix-morse-e2e' of github.com:buildwithgrove/path into f…
commoddity Dec 18, 2024
da6c051
chore: merge conflicts
commoddity Dec 18, 2024
5d283b6
chore: merge conflicts
commoddity Dec 18, 2024
2e14f57
fix: update E2E test branch fixes
commoddity Dec 18, 2024
aa63306
fix: disable lua filter for /healthz route
commoddity Dec 18, 2024
3cba419
chore: merge conflicts
commoddity Dec 18, 2024
4022eeb
chore: merge conflicts
commoddity Dec 19, 2024
c24867d
Review envoy/allowed-services.template.lua
Olshansk Dec 19, 2024
3e78dce
chore: update endpoint store test to be consistent with example gatew…
commoddity Dec 19, 2024
da64767
chore: add link to service_qos.go file
commoddity Dec 19, 2024
8d161eb
chore: merge conflicts
commoddity Dec 19, 2024
783bca1
chore: fix casing in header examples
commoddity Dec 19, 2024
52a147e
chore: makefile target fix and remove unused struct in config
commoddity Dec 19, 2024
d21fae0
Review envoy_config.md and add support for proper syntax highlighting
Olshansk Dec 19, 2024
96cfe9d
Review the introduction
Olshansk Dec 19, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 4 additions & 24 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -235,33 +235,13 @@ init_envoy: copy_envoy_config copy_gateway_endpoints ## Runs copy_envoy_config a

commoddity marked this conversation as resolved.
Show resolved Hide resolved
.PHONY: copy_envoy_config
copy_envoy_config: ## Substitutes the sensitive 0Auth environment variables in the template envoy configuration yaml file and outputs the result to .envoy.yaml
@if [ ! -f ./local/path/envoy/envoy.yaml ]; then \
mkdir -p local/path/envoy; \
./envoy/scripts/copy_envoy_config.sh; \
echo "###########################################################"; \
echo "### Created ./local/path/envoy/envoy.yaml ###"; \
echo "### README: Please ensure the configuration is correct. ###"; \
echo "###########################################################"; \
else \
echo "######################################################################"; \
echo "### ./local/path/envoy/envoy.yaml already exists, not overwriting. ###"; \
echo "######################################################################"; \
fi
@mkdir -p local/path/envoy;
@./envoy/scripts/copy_envoy_config.sh;

.PHONY: copy_gateway_endpoints
copy_gateway_endpoints: ## Copies the example gateway endpoints YAML file from the PADS repo to ./local/path/envoy/.gateway-endpoints.yaml
@if [ ! -f ./local/path/envoy/gateway-endpoints.yaml ]; then \
mkdir -p local/path/envoy; \
./envoy/scripts/copy_gateway_endpoints_yaml.sh; \
echo "###########################################################"; \
echo "### Created ./local/path/envoy/gateway-endpoints.yaml ###"; \
echo "### README: Please update this file with your own data. ###"; \
echo "###########################################################"; \
else \
echo "##################################################################################"; \
echo "### ./local/path/envoy/gateway-endpoints.yaml already exists, not overwriting. ###"; \
echo "##################################################################################"; \
fi
@mkdir -p local/path/envoy;
@./envoy/scripts/copy_gateway_endpoints_yaml.sh;

###############################
### Generation Make Targets ###
Expand Down
13 changes: 11 additions & 2 deletions Tiltfile
Original file line number Diff line number Diff line change
Expand Up @@ -119,15 +119,24 @@ if MODE == "path_with_auth":

# Import Envoy Auth configuration file into Kubernetes ConfigMaps
configmap_create(
"envoy-config", from_file="./local/path/envoy/.envoy.yaml", watch=True
"envoy-config",
from_file="./local/path/envoy/.envoy.yaml",
watch=True,
)
configmap_create(
"allowed-services",
from_file="./local/path/envoy/.allowed-services.lua",
watch=True,
)
configmap_create(
"gateway-endpoints",
from_file="./local/path/envoy/.gateway-endpoints.yaml",
watch=True,
)
configmap_create(
"ratelimit-config", from_file="./local/path/envoy/.ratelimit.yaml", watch=True
"ratelimit-config",
from_file="./local/path/envoy/.ratelimit.yaml",
watch=True,
)

# 1. Build the External Authorization Server image from envoy/auth_server/Dockerfile
Expand Down
1 change: 0 additions & 1 deletion config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ type (
MessagingConfig MessagingConfig `yaml:"messaging_config"`
}
ServiceConfig struct {
Alias string `yaml:"alias"`
RequestTimeout time.Duration `yaml:"request_timeout"`
}
)
Expand Down
13 changes: 0 additions & 13 deletions config/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,6 @@ func Test_LoadGatewayConfigFromYAML(t *testing.T) {
http_config:
retries: 3
timeout: 5000
request_config:
retries: 3
relay_signing_key: "gateway-private-key"
signed_aats:
f9076ec39b2a495883eb59740d566d5fa2e2b222:
Expand All @@ -185,17 +183,6 @@ func Test_LoadGatewayConfigFromYAML(t *testing.T) {
yamlData: "invalid_yaml: [",
wantErr: true,
},
{
name: "should return error for duplicate service alias",
filePath: "duplicate_service_alias.yaml",
yamlData: `
morse_config:
serviceAliases:
eth: "0021"
eth: "0022"
`,
wantErr: true,
},
}

for _, test := range tests {
Expand Down
1 change: 0 additions & 1 deletion config/examples/config.shannon_example.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,3 @@ shannon_config:
# hydrator_config:
# service_ids:
# - "anvil"
# - "F00C"
Loading
Loading