jmc265 / docker-events-pushbullet

Receive a PushBullet notification on Docker events

Home Page:https://github.com/jmc265/docker-events-pushbullet

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Docker Events PushBullet

Receive PushBullet notifications when on docker container events

How it works

This image connects to the host machine socket, through a volume mapping, and listen Docker Events API.

When specified events are triggered it sends the affected containers' information to PushBullet.

If no events are specified in the enironment variables, these are the default ones: "create","update","destroy","die","kill","pause","unpause","start","stop"

Build

You must create a release tag in order to build and publish this image.

./build-all.sh

Run

First get a PushBullet Access Token

Run (default events)

docker run \
    -d --restart=always \
    -v /var/run/docker.sock:/var/run/docker.sock \
    -e PB_API_KEY="INSERT-KEY-HERE" \
    jmc265/docker-events-pushbullet:latest

Run (custom events)

docker run \
    -d --restart=always \
    -v /var/run/docker.sock:/var/run/docker.sock \
    -e PB_API_KEY="INSERT-KEY-HERE" \
    -e EVENTS="die,destroy,kill"
    jmc265/docker-events-pushbullet:latest

Run (Docker Compose/Stack)

version: '2'
 
services:
  docker-events:
    container_name: docker-events
    image: jmc265/docker-events-pushbullet:latest
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
    environment:
      - PB_API_KEY=INSERT-KEY-HERE
      - EVENTS=die,destroy,kill
    restart: unless-stopped

License

Apache License Version 2.0

About

Receive a PushBullet notification on Docker events

https://github.com/jmc265/docker-events-pushbullet

License:Apache License 2.0


Languages

Language:Python 79.1%Language:Shell 13.0%Language:Dockerfile 7.9%