35 lines
894 B
Markdown
35 lines
894 B
Markdown
# Prometheus за SSO
|
|
|
|
## Схема
|
|
|
|
```
|
|
https://prometheus.buryans.ru (VPS, Let's Encrypt)
|
|
│ proxy_pass
|
|
▼
|
|
192.168.1.134:9113 (oauth2-proxy, CT134)
|
|
│ OIDC → Authentik
|
|
▼
|
|
192.168.1.134:9090 (Prometheus)
|
|
```
|
|
|
|
## Компоненты
|
|
|
|
| Что | Где |
|
|
|---|---|
|
|
| VPS vhost | `/etc/nginx/conf.d/prometheus.conf` |
|
|
| Сертификат | `/etc/letsencrypt/live/prometheus.buryans.ru/` |
|
|
| oauth2-proxy | CT134, контейнер `oauth2-proxy-prometheus`, порт 9113 |
|
|
| Провайдер | Authentik, приложение `prometheus` |
|
|
|
|
## Проверка
|
|
|
|
```
|
|
curl -sI https://prometheus.buryans.ru/ | head -3
|
|
# ожидаем 302 → /application/o/authorize/
|
|
```
|
|
|
|
## Откат
|
|
|
|
1. Остановить контейнер `oauth2-proxy-prometheus`.
|
|
2. Удалить `/etc/nginx/conf.d/prometheus.conf` на VPS, `nginx -t && reload`.
|