Sign inSign up

budry/release-monitor

By budry

Updated about 8 years ago

Simple commandline app for watching releases a running tasks when is a new release published.

Image
0

226

budry/release-monitor repository overview

This package is not completed

Motivation

From time to time I need to be notificated when some library/package/apps is updated to a new version. For example, I manage ARM build of docker/registry and I need hook for run automatic build when official app is updated to a new version. Because GitHub doest not have any simple mechanism for that (has only atom feed but without any notifications) I create this simple app.

How to use it

The best way how to use this app is as docker image.

docker run \
    -v /path/to/config/directory:/etc/release-monitor \
    -v /path/to/data/directory:/var/lib/release-monitor \
    budry/release-monitor

Required is only the first volume, application needs to have configuration file. The second volume is used for store last process release notification. When you don't use it and restart container application, resend all notification from beginning.

Configuration file

Configuration file must have name config.json and must contain valid JSON. File cannot be empty, minimal content is {}

Example configuration
{
    "interval": "@daily",
    "monitors": [
        {
            "name": "Docker registry",
            "url": "https://github.com/Budry/docker-registry-arm",
            "commands": [
                "curl --header \"Content-Type: application/json\" --request POST --data %%RELEASE%% <CI server endpoint>"
            ]
        }
    ]
}

This example send HTTP request with release info in json format to my CI server and run automatic build.

Format
  • root
    • interval - CRON string. You can use format described here
    • monitors - list of monitors
  • monitor
    • name - Your monitor name. Name is used for remember last processed release
    • url - URL address to your package. Each service as GitHub, Bitbucket, GitLab has own adapter (currently is GitHub only)
    • commands - list of strings. Each command will be run and you can use %%RELEASE%% placeholder for insert release info. All commands are execute for each new release
Release info

Each release has simple format

{
    "version": "",
    "date": "" 
}

Tag summary

Content type

Image

Digest

Size

177.4 MB

Last updated

about 8 years ago

docker pull budry/release-monitor