Skip to content

Commit a933411

Browse files
committed
Remove /metrics from the website
Similar data is already generated by fsreport available for the relay operator and metrics for prometheus are generated by mtail. Closes <#431>
1 parent dd3cf4d commit a933411

File tree

8 files changed

+7
-77
lines changed

8 files changed

+7
-77
lines changed

ARCHITECTURE.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,7 @@ graph LR;
1717
nginx-internal --- autoconfig.xml;
1818
certs-nginx[("`TLS certs
1919
/var/lib/acme`")] --> nginx-internal;
20-
cron --- chatmail-metrics;
2120
cron --- acmetool;
22-
chatmail-metrics --- website;
2321
acmetool --> certs[("`TLS certs
2422
/var/lib/acme`")];
2523
nginx-external --- |993|dovecot;

README.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -224,9 +224,6 @@ A short overview of `chatmaild` services:
224224
is a small bot for test purposes.
225225
It simply echoes back messages from users.
226226

227-
- [`chatmail-metrics`](https://github.com/chatmail/relay/blob/main/chatmaild/src/chatmaild/metrics.py)
228-
collects some metrics and displays them at `https://example.org/metrics`.
229-
230227
### Home page and getting started for users
231228

232229
`cmdeploy run` also creates default static web pages and deploys them

chatmaild/pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ doveauth = "chatmaild.doveauth:main"
2626
chatmail-metadata = "chatmaild.metadata:main"
2727
filtermail = "chatmaild.filtermail:main"
2828
echobot = "chatmaild.echo:main"
29-
chatmail-metrics = "chatmaild.metrics:main"
3029
chatmail-expire = "chatmaild.expire:main"
3130
chatmail-fsreport = "chatmaild.fsreport:main"
3231
lastlogin = "chatmaild.lastlogin:main"

chatmaild/src/chatmaild/metrics.py

Lines changed: 0 additions & 32 deletions
This file was deleted.

chatmaild/src/chatmaild/tests/test_metrics.py

Lines changed: 0 additions & 24 deletions
This file was deleted.

cmdeploy/src/cmdeploy/__init__.py

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -108,16 +108,13 @@ def _install_remote_venv_with_chatmaild(config) -> None:
108108
],
109109
)
110110

111-
files.template(
112-
src=importlib.resources.files(__package__).joinpath("metrics.cron.j2"),
113-
dest="/etc/cron.d/chatmail-metrics",
114-
user="root",
115-
group="root",
116-
mode="644",
117-
config={
118-
"mailboxes_dir": config.mailboxes_dir,
119-
"execpath": f"{remote_venv_dir}/bin/chatmail-metrics",
120-
},
111+
files.file(
112+
path="/etc/cron.d/chatmail-metrics",
113+
present=False,
114+
)
115+
files.file(
116+
path="/var/www/html/metrics",
117+
present=False,
121118
)
122119

123120
# install systemd units

cmdeploy/src/cmdeploy/metrics.cron.j2

Lines changed: 0 additions & 1 deletion
This file was deleted.

cmdeploy/src/cmdeploy/nginx/nginx.conf.j2

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -76,10 +76,6 @@ http {
7676
try_files $uri $uri/ =404;
7777
}
7878

79-
location /metrics {
80-
default_type text/plain;
81-
}
82-
8379
location /new {
8480
if ($request_method = GET) {
8581
# Redirect to Delta Chat,

0 commit comments

Comments
 (0)