Skip to content

homecentr/docker-prometheus-alertmanager

Repository files navigation

Project status

CI/CD on master Regular Docker image vulnerability scan

HomeCentr - prometheus-alertmanager

This Docker image is a repack of the original Prometheus Alertmanager with the usual Homecentr bells and whistles.

Usage

version: "3.7"
services:
  prometheus-alertmanager:
    build: .
    image: homecentr/prometheus-alertmanager:local
    environment:
      ALERTMANAGER_ARGS: "--log.level=debug"
    volumes:
      - ./example:/config
    ports:
      - 9093:9093
    restart: unless-stopped

Environment variables

Name Default value Description
PUID 7077 UID of the user prometheus-alertmanager should be running as.
PGID 7077 GID of the user prometheus-alertmanager should be running as.
ALERTMANAGER_ARGS Additional command line arguments passed to the Alertmanager executable. Do not specify the --config.file and --storage.path these are already set by the image.

Exposed ports

Port Protocol Description
9093 TCP Alert manager API

Volumes

Container path Description
/config Alertmanager Configuration. The configuration should be in /config/alertmanager.yml.
/alertmanager Alertmanager state in case it is restarted. Make sure the PUID/PGID grants the process the rights to write into this directory.

Security

The container is regularly scanned for vulnerabilities and updated. Further info can be found in the Security tab.

Container user

The container supports privilege drop. Even though the container starts as root, it will use the permissions only to perform the initial set up. The prometheus-alertmanager process runs as UID/GID provided in the PUID and PGID environment variables.

⚠️ Do not change the container user directly using the user Docker compose property or using the --user argument. This would break the privilege drop logic.