-
Notifications
You must be signed in to change notification settings - Fork 296
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
🐛 Allow external redis/rabbitmq secret creation even if the broke… #3903
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hi there @afreyermuth98 👋
Thanks for your contribution! Do you mind adding two things:
- a few helm unit tests which assert the scenario you are trying to fix
- add an entry to the root
CHANGELOG.md
under (Unreleased > Fixed)
Thank you! 👊
Hey ! |
@afreyermuth98 lastly you just need to sign the CLA 🙂 |
@joeyorlando Hmm weird i've signed it just after my commit 🤔
|
looks to be fine now, thank you! |
@afreyermuth98 one last thing. One of the new helm unit tests is failing: https://github.com/grafana/oncall/actions/runs/7971753982/job/21762105142#step:5:1 |
@joeyorlando Yeah I don't really understand why. The test fails because the password is not set but it's the normal functioning isn't it ? If I'm wrong I would be glad to be highlighted :) UPDATE : it should be fixed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what about the case where externalRedis and externalRabbitmq are set?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll do it ;)
Hey @joeyorlando I've modified the tests. It passed but it's not perfect and I would be glad to be highlighted. |
One trick I just figured out is if you add a # test file
- it: externalRedis.password and externalRabbitmq.password -> should create secret -redis-external and -rabbitmq-external
templates:
- engine/deployment.yaml
- celery/deployment.yaml
set:
rabbitmq.enabled: false
redis.enabled: false
broker.type: rabbitmq
externalRedis:
host: redis.example.com
username: user123
password: abcd123
externalRabbitmq:
host: custom-host
user: custom-user
password: custom-password
asserts:
... other assertions
- matchSnapshot: {}
template: secrets.yaml then in externalRedis.password and externalRabbitmq.password -> should create secret -redis-external and -rabbitmq-external:
1: |
apiVersion: v1
data:
MIRAGE_SECRET_KEY: aEV4RmNqYm5sdllPVUtqVmZ2ZG1oc3N4NXRQNGpuc0E2dzV5eXJrOA==
SECRET_KEY: WjNGRVUzak9IMkM3TTBiQ0dyZUpDTmZ5dnQ0aEticGFFaEdXUk5IcQ==
kind: Secret
metadata:
labels:
app.kubernetes.io/instance: oncall
app.kubernetes.io/managed-by: Helm
app.kubernetes.io/name: oncall
app.kubernetes.io/version: v1.3.99
helm.sh/chart: oncall-1.3.99
name: oncall
type: Opaque
2: |
apiVersion: v1
data:
rabbitmq-password: Y3VzdG9tLXBhc3N3b3Jk
kind: Secret
metadata:
name: oncall-rabbitmq-external
type: Opaque
3: |
apiVersion: v1
data:
redis-password: YWJjZDEyMw==
kind: Secret
metadata:
name: oncall-redis-external
type: Opaque turns out it was simply the |
Ooook I was wondering about this documentIndex but didn't find a conclusion about it ahah. Thanks a lot ! :D |
What this PR does
This PR allows the chart to create the secret of your redis / rabbitmq even if it's not the broker.
Actually, this is blocking if we want to have a redis as cache and a rabbitmq as broker for example
Which issue(s) this PR fixes
Closes #2979
Checklist
pr:no public docs
PR label added if not required)CHANGELOG.md
updated (orpr:no changelog
PR label added if not required)