-
Notifications
You must be signed in to change notification settings - Fork 904
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
Propagate AWS target group hash to rollout metadata #1608
Comments
Similar to PodTemplateHashValue that can be referred in analysis templates, requirement is to refer targetGroup values for services. apiVersion: argoproj.io/v1alpha1
kind: AnalysisTemplate
metadata:
name: error-count
spec:
args:
- name: targetgroup
metrics:
- name: error-count
initialDelay: 1m
interval: 1m
count: 3
failureCondition: result > 50
provider:
wavefront:
address: intuit.wavefront.com
query: >
sum(default(0, ts(aws.alb.httpcode_target_5xx_count, targetgroup={{args.canary-targetgroup}})))
---
kind: Rollout
apiVersion: argoproj.io/v1alpha1
metadata:
name: rollout
spec:
# Set replicas to null when enabling HPA, sample: 'replicas: null'
replicas: 2
strategy:
canary:
canaryService: desired-service
stableService: stable-service
canaryMetadata:
annotations:
role: canary
labels:
role: canary
stableMetadata:
annotations:
role: stable
labels:
role: stable
steps:
- setCanaryScale:
replicas: 1
- pause: { }
- setWeight: 5
- setCanaryScale:
matchTrafficWeight: true
- analysis:
templates:
- templateName: error-count
args:
- name: stable-targetgroup
valueFrom:
targetGroupValue: StableService
- name: canary-targetgroup
valueFrom:
targetGroupValue: CanaryService 2 features to add. |
@jessesuen let me know if the above make sense or if there is a better way to do? |
Hello. Also - do you expect the full ARN to be persisted as a label on the service? Or just the unique part of it? And what should I do when there are several TargetGroupBindings on the same service? Is this even a valid scenario? |
you dont need full ARN, just the id is enough, for example arn:aws:elasticloadbalancing:us-east-2:795188202216:targetgroup/k8s-testargo-albrollo-2249f2dae0/7010986ede9433b1 can you post the ingress and rollout manifest files? |
Sure. I was mostly using the ALB getting started guide. apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
name: rollouts-demo-ingress
annotations:
kubernetes.io/ingress.class: alb
alb.ingress.kubernetes.io/scheme: internet-facing
spec:
rules:
- http:
paths:
- path: /*
backend:
serviceName: rollouts-demo-root
servicePort: use-annotation and Rollout: apiVersion: argoproj.io/v1alpha1
kind: Rollout
metadata:
name: rollouts-demo
spec:
replicas: 1
strategy:
canary:
canaryService: rollouts-demo-canary
stableService: rollouts-demo-stable
trafficRouting:
alb:
ingress: rollouts-demo-ingress
servicePort: 80
rootService: rollouts-demo-root
steps:
- setWeight: 5
- pause: {}
revisionHistoryLimit: 2
selector:
matchLabels:
app: rollouts-demo
template:
metadata:
labels:
app: rollouts-demo
spec:
containers:
- name: rollouts-demo
image: argoproj/rollouts-demo:blue
ports:
- name: http
containerPort: 8080
protocol: TCP
resources:
requests:
memory: 32Mi
cpu: 5m I installed the ALB resources and controller from v2.3, and after some fiddling got everything to work with internet-facing ingress (I had to manually set the availability zones of the ALB to use the public subnets, instead of the private ones). |
oh, I think my problem is related to the |
For the 2nd side of the task - I've been looking at adding the stable and canary (or active/preview) to the Also - do you expect the optional values of |
Instead of this: valueFrom:
targetGroupValue: StableService
- name: canary-targetgroup
valueFrom:
targetGroupValue: CanaryService When we spoke about this a while back, I was originally thinking we could have valueFrom do this in a more generic way, referencing field metadata in the status. This way it would not be specific to AWS. Also, it would allow the work items could be split into two tasks:
|
Thanks for the comment @jessesuen . I think this makes sense to have a more generic option without sticking to AWS. @noam-codefresh let me know above comment make sense. |
We have two issues for this already:
I think we should dup this one |
@noam-codefresh I will close this one. Please comment on #1241 and I will assign it to you. |
Summary
What change needs making?
Similar to canary/stable hash values, propagate AWS target group hashes for canary & stable
Will be available only if --aws-verify-target-group enabled
Use Cases
When would you use this?
Message from the maintainers:
Impacted by this bug? Give it a 👍. We prioritize the issues with the most 👍.
The text was updated successfully, but these errors were encountered: