Ambassador: We want regex pattern rewrite

Created on 29 Jan 2019  路  9Comments  路  Source: datawire/ambassador

Hope ambassador to support some rules like below:

      getambassador.io/config: |
        ---
        apiVersion: ambassador/v0
        kind:  Mapping
        name:  regex_pattern_mapping
        prefix_regex: true
        prefix: /svc/([\w-]+)/([\w-]+)/
        service: $2.$1:80
        host_rewrite: $2.$1
        ---
        apiVersion: ambassador/v0
        kind:  Mapping
        name:  regex_pattern_mapping2
        prefix_regex: true
        prefix: /svc/{namespace}/{svcname}/
        service: $namespace.$svcname:80
        host_rewrite: $namespace.$svcname
stale

Most helpful comment

not stale

All 9 comments

PR would be great. (Or at least, an investigation into whether or not this is a supported Envoy feature.)

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

not stale

It looks like envoy support for this recently landed https://github.com/envoyproxy/envoy/pull/10050. Regex-based path rewriting would be really helpful for us, too.

I would implement this if I know how to do it :). May I help in any form?

This would be really helpful.

FYI the Ambassador's regex_rewrite feature is just released today. You can read more about it here in docs.

@alphashr, cool! Thanks for reminding me. This can be helpful.

Was this page helpful?
0 / 5 - 0 ratings