Skip to content

Commit

Permalink
nagios: Add go-smtp-send utility to send SMTP emails
Browse files Browse the repository at this point in the history
  • Loading branch information
hverr committed Jan 19, 2017
1 parent 0c351a7 commit 7ec8e22
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
9 changes: 9 additions & 0 deletions nagios-lighttpd/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,12 @@ Launch
lxdfile build nagios
lxdfile launch nagios nagios -i passwd.inject -i configure.inject
```

Extras
------

Also contains the [go-smtp-send](https://github.com/hverr/go-smtp-send) utility to easily send mails using SMTP.

- The utility is installed in `/usr/local/nagios/libexec/go-smtp-send`.
- The utility requires a configuration file in `/etc/go-smtp-send.yaml` (see above link).
- An inject script can be used to inject the configuration file.
6 changes: 6 additions & 0 deletions nagios-lighttpd/lxdfile
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,12 @@ RUN cd nagios-plugins-release-$PLUGIN_VERSION && \
make -j$(nproc) && \
make install

# SMTP
ENV SMTP_SEND_VERSION v1
ENV SMTP_SEND_URL https://github.com/hverr/go-smtp-send/releases/download/$SMTP_SEND_VERSION/go-smtp-send_linux_amd64
RUN curl -L "$SMTP_SEND_URL" -o /usr/local/nagios/libexec/go-smtp-send && \
chmod 0755 /usr/local/nagios/libexec/go-smtp-send

# Lighttpd
RUN apt-get install -y \
php7.0-cgi
Expand Down

0 comments on commit 7ec8e22

Please sign in to comment.