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

Implement NGINX ingress header regex matching #546

Merged
merged 4 commits into from Apr 3, 2020

Conversation

stefanprodan
Copy link
Member

This PR allows specifying a header regex expression in the canary analysis that will translate to canary-by-header-pattern annotation on the canary ingress object.

Example:

apiVersion: flagger.app/v1beta1
kind: Canary
spec:
  ingressRef:
    apiVersion: networking.k8s.io/v1beta1
    kind: Ingress
    name: podinfo
  analysis:
    match:
    - headers:
        x-user:
          regex: ".*insider.*"

Note that the canary-by-header-pattern feature is not yet released but it's scheduled for v0.31.0 kubernetes/ingress-nginx#5114

Fix: #545

Copy link
Collaborator

@mathetake mathetake left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@stefanprodan stefanprodan merged commit db4a15e into master Apr 3, 2020
@stefanprodan stefanprodan deleted the nginx-header-regex branch April 3, 2020 06:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature Request: Add support for "canary-by-header-pattern" for Nginx Ingress canary matching
2 participants