cachethq / cachethq/Docker

Unsuscribe link in Email broken for dockerized cachet

Open
#329 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Shell
Stars
439
Forks
271
PR merge metrics
No merged PRs in 30d

Description

I am deploying several instances of cachet (2.3.14) in our docker swarm environment. I have written a python service that queries kibana and opens incidents when needed in cachet.
Everything is working as expected.

I have then added configuration to the swarmfile to send emails through mailgun; also this part seems to work flawlessly. I did get the confirmation email, and after confirmation I started receiving emails for each incident event.

Now, revising all components before releasing the solution to prod, I have noticed that the "unsubscribe" and "manage subscription" links are broken.

Instead of the full domain name of the cachet instance, the URL is built using the container name + port:

`http://preprod_cachet_cachet_customer:8000/subscribe/manage/a8C7frCxRR5cwQcNwGaODh3NyifmNwiSENg29m8yxy`

The only place I am using that notation is in my python service. The service does not have access to a public DNS, so I am pointing it to cachet using the stack + service_name (docker embedded dns service for internal networks). This is also somehow "safer" and faster, because the request is local to the LAN.

My guess is that the unsuscribe email link is generated using the header of the request that generated the notification in the first place. This is not a sane behavior, because it forces api calls to be sent through the internet.

This is a blocker for our usage of cachet in production. Can this behavior be altered though some configuration parameter?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.