Merge ~valentinviennot/ubuntu-docker-images:update-prometheus-alertmanager-readme into ~ubuntu-docker-images/ubuntu-docker-images/+git/prometheus-alertmanager:edge

Proposed by Valentin Viennot
Status: Merged
Merged at revision: 1119ed00e0f5942f5905a64da24d030ca16540eb
Proposed branch: ~valentinviennot/ubuntu-docker-images:update-prometheus-alertmanager-readme
Merge into: ~ubuntu-docker-images/ubuntu-docker-images/+git/prometheus-alertmanager:edge
Diff against target: 52 lines (+7/-12)
1 file modified
oci/README.md (+7/-12)
Reviewer Review Type Date Requested Status
Lucas Kanashiro Approve
Richard Harding (community) Needs Fixing
Sergio Durigan Junior Pending
Review via email: mp+394059@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Lucas Kanashiro (lucaskanashiro) wrote :

Minor fix needed.

review: Needs Fixing
Revision history for this message
Richard Harding (rharding) wrote :

Just a partial review as it looks like Sergio has this, but -1 on any non-UTC timezone config if we have to have it.

review: Needs Fixing
Revision history for this message
Lucas Kanashiro (lucaskanashiro) wrote :

The TZ config is on our radar. I am approving this MP.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/oci/README.md b/oci/README.md
index 8367dc5..3f3324a 100644
--- a/oci/README.md
+++ b/oci/README.md
@@ -6,7 +6,7 @@ The Alertmanager handles alerts sent by client applications such as the Promethe
66
7## Tags7## Tags
88
9* `0.21.0`, `0.21`, `beta` - **/!\ this is a beta release**9* `0.21.0-focal`, `0.21.0`, `0.21-focal`, `0.21`, `focal`, `beta` - **/!\ this is a beta release**
1010
11## Architectures supported11## Architectures supported
1212
@@ -17,24 +17,19 @@ The Alertmanager handles alerts sent by client applications such as the Promethe
17### Docker CLI17### Docker CLI
1818
19```sh19```sh
20$ docker run --name alertmanager -e TZ=UTC -d squeakywheel/prometheus-alertmanager:edge20$ docker run -d --name alertmanager -p 30093:9093 -e TZ=Europe/London squeakywheel/prometheus-alertmanager:edge
21```21```
2222
23Since containers are ephemeral, you may want to use persistent data rather than initializing a new database for each newly launched container. To do this, you can use docker volumes:23Access your Prometheus Alertmanager instance at `localhost:30093`.
24
25```sh
26$ docker run --name alertmanager -v /path/to/persisted/data:/alertmanager -e TZ=UTC -d squeakywheel/prometheus-alertmanager:edge
27```
28
29**Important note**: the directory you will be using to persist the data needs to belong to `nogroup:nobody`. You can run `chown nogroup:nobody <path_to_persist_data>` before launching your container.
3024
31#### Parameters25#### Parameters
3226
33| Parameter | Description |27| Parameter | Description |
34|---|---|28|---|---|
35| `-e TZ=UTC` | Timezone. |29| `-e TZ=UTC` | Timezone. |
36| `-v /path/to/persisted/data:/alertmanager` | Pass the directory used to persist the data. |30| `-p 30093:9093` | Expose Prometheus Alertmanager server on `localhost:30093`. |
37| `-v /path/to/alertmanager/config/file/alertmanager.yml:/etc/prometheus/alertmanger.yml` | Pass a custom config file. |31| `-v /path/to/persisted/data:/alertmanager` | Persist data instead of initializing a new database for each newly launched container. **Important note**: the directory you will be using to persist the data needs to belong to `nogroup:nobody`. You can run `chown nogroup:nobody <path_to_persist_data>` before launching your container.|
32| `-v /path/to/alertmanager/config/file/alertmanager.yml:/etc/prometheus/alertmanger.yml` | Pass a custom config file (download this [example file](https://git.launchpad.net/~canonical-server/ubuntu-server-oci/+git/prometheus-alertmanager/plain/oci/examples/config/alertmanager.yml)). |
3833
39#### Testing/Debugging34#### Testing/Debugging
4035
@@ -53,7 +48,7 @@ With microk8s running, enable the `dns` and `storage` add-ons:
53$ microk8s enable dns storage48$ microk8s enable dns storage
54 ```49 ```
5550
56Create a configmap for the configuration file (check the upstream documentation [here](https://prometheus.io/docs/alerting/latest/configuration/)):51Create a configmap for the configuration file (check the [Prometheus documentation](https://prometheus.io/docs/alerting/latest/configuration/)):
5752
58```sh53```sh
59$ microk8s kubectl create configmap alertmanager-config --from-file=alertmanager=config/alertmanager.yml54$ microk8s kubectl create configmap alertmanager-config --from-file=alertmanager=config/alertmanager.yml

Subscribers

People subscribed via source and target branches