Skip to content

Commit 56ed3b6

Browse files
committed
Update README docker example, set Dockerfile maintainer label, Update systemd example
1 parent e485af9 commit 56ed3b6

File tree

3 files changed

+13
-2
lines changed

3 files changed

+13
-2
lines changed

Dockerfile

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
ARG ARCH="amd64"
22
ARG OS="linux"
33
FROM quay.io/prometheus/busybox-${OS}-${ARCH}:glibc
4+
LABEL maintainer="Trey Dockendorf <treydock@gmail.com>"
45
ARG ARCH="amd64"
56
ARG OS="linux"
67
COPY .build/${OS}-${ARCH}/ssh_exporter /ssh_exporter

README.md

+10
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,16 @@ Example of running the Docker container
7272
docker run -d -p 9312:9312 -v "ssh_exporter.yaml:/ssh_exporter.yaml:ro" treydock/ssh_exporter
7373
```
7474

75+
Example of running the Docker container and making SSH private key available.
76+
This requires setting `private_key` value to `/.ssh/id_rsa`.
77+
78+
```
79+
docker run -d -p 9312:9312 \
80+
-v "ssh_exporter.yaml:/ssh_exporter.yaml:ro" \
81+
-v "/home/prometheus/.ssh/id_rsa:/.ssh/id_rsa:ro" \
82+
treydock/ssh_exporter
83+
```
84+
7585
## Install
7686

7787
Download the [latest release](https://github.com/treydock/ssh_exporter/releases)

systemd/ssh_exporter.service

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
[Unit]
2-
Description=Prometheus ssh_exporter
2+
Description=Prometheus SSH Exporter
33
Wants=basic.target
44
After=basic.target network.target
55

66
[Service]
77
User=ssh_exporter
88
Group=ssh_exporter
9-
ExecStart=/usr/local/bin/ssh_exporter --config.file=/etc/ssh_exporterssh_exporter.yaml
9+
ExecStart=/usr/local/bin/ssh_exporter --config.file=/etc/ssh_exporter.yaml --web.listen-address=:9312
1010
ExecReload=/bin/kill -HUP $MAINPID
1111
KillMode=process
1212
Restart=always

0 commit comments

Comments
 (0)