Browse Source

Rename service/main file to match repo

master
Silke 3 years ago
parent
commit
a51f455177
  1. 4
      README.md
  2. 2
      alertmanager_matrix.go
  3. 4
      alertmanager_matrix.service

4
README.md

@ -3,8 +3,8 @@ Service for sending alerts from the Alertmanager webhook to a Matrix room.
## Usage
The service is configured either through command line arguments or environment variables.
With the provided systemd service file (`alertmanager-matrix.service`),
the configuration is done in `/etc/default/alertmanager-matrix` as follows:
With the provided systemd service file (`alertmanager_matrix.service`),
the configuration is done in `/etc/default/alertmanager_matrix` as follows:
```sh
HOMESERVER=http://localhost:8008

2
alertmanager-matrix.go → alertmanager_matrix.go

@ -81,8 +81,6 @@ func main() {
setMapFromJsonFile(&alertColors, colorFile)
}
log.Printf("%+v\n%+v\n", alertIcons, alertColors)
log.Printf("Connecting to Matrix homeserver at %s as %s", homeserver, userID)
client, err = matrix.NewClient(homeserver, userID, token)
if err != nil {

4
alertmanager-matrix.service → alertmanager_matrix.service

@ -5,8 +5,8 @@ After=network-online.target
[Service]
Restart=always
DynamicUser=yes
EnvironmentFile=/etc/default/alertmanager-matrix
ExecStart=/usr/local/bin/alertmanager-matrix
EnvironmentFile=/etc/default/alertmanager_matrix
ExecStart=/usr/local/bin/alertmanager_matrix
[Install]
WantedBy=multi-user.target
Loading…
Cancel
Save