Skip to content

Setup mtail#388

Merged
link2xt merged 3 commits intomainfrom
link2xt/mtail
Oct 14, 2024
Merged

Setup mtail#388
link2xt merged 3 commits intomainfrom
link2xt/mtail

Conversation

@link2xt
Copy link
Copy Markdown
Contributor

@link2xt link2xt commented Jul 30, 2024

This runs mtail at localhost, so you can query http://127.0.0.1:3903/metrics and get metrics collected by parsing the log files to get some counters of the number of sent/received mails.

This can then be plugged into Prometheus. Setting up Prometheus is outside of the scope of cmdeploy.

What is missing is a setting in the .ini file to set the host and port. Listening on 127.0.0.1 is not very useful, normally you would have a wireguard network for metric collection and make mtail listen on the IP address from this network.

Another problem currently is that deployment fails while trying to copy mtail binary if it is already running. We should stop mtail service before replacing the binary somehow.

@link2xt link2xt marked this pull request as draft July 31, 2024 09:38
@link2xt link2xt marked this pull request as ready for review October 11, 2024 22:32
@hpk42
Copy link
Copy Markdown
Contributor

hpk42 commented Oct 13, 2024

Another problem currently is that deployment fails while trying to copy mtail binary if it is already running. We should stop mtail service before replacing the binary somehow.

but this makes it hard to merge right away, no?

also, there is an "mtail" debian package which is probably better to use than downloading from google server and unpacking etc.

Comment thread cmdeploy/src/cmdeploy/__init__.py Outdated
@link2xt link2xt force-pushed the link2xt/mtail branch 3 times, most recently from 5054e61 to 7fac976 Compare October 14, 2024 07:13
Comment thread CHANGELOG.md Outdated
If you want to collect the metrics with Prometheus,
setup a private network (e.g. WireGuard interface)
and assign an IP address from this network to the host.
If unsure, set this setting to `127.0.0.1`.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

why is it a required setting? It should be fine to leave it empty, and then no mtail is setup or run?

@link2xt link2xt merged commit 5515607 into main Oct 14, 2024
@link2xt link2xt deleted the link2xt/mtail branch October 14, 2024 09:18
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.

2 participants