• Stars
    star
    5
  • Rank 2,861,937 (Top 57 %)
  • Language
    Go
  • Created over 7 years ago
  • Updated almost 7 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Lite CI/CD tool with Slack notifications

meteor Build Status Gitter

The lightweight and quick continuous delivery tool

meteor

Image from clipartfest.com

Purpose

It is very simple application with configuration and it is very quick. That's why it could be used on ARM's devices also, like RaspberryPI, to execute your BASH pipelines or scripts. Possibility to integrate it with an external systems (for example: TravisCI and Slack) make it flexible.

Installation

build:
go build .
start command:
./meteor -conf meteor.conf
start with systemd:
mkdir /opt/meteor
cp -r {meteor,meteor.conf,tasks} /opt/meteor/
cp examples/systemd/meteor.service /etc/systemd/system/
systemctl daemon-reload
systemctl enable meteor
systemctl start meteor

General Configuration:

Main configuration for the service are placed in meteor.conf. Also, there is an additional configuration for each task, which is placed in ./tasks/ directory.

General configuration file contains of:

listen - host and port to listening(example: ":8080")

username - username for basic authentication password - password for basic authentication

cmd-interpreter - main interpreter for pipelines (default: /bin/bash) cmd-flag - interpreter's flag (default: -c)

slack-token - Slack's verification token, for integration with Slack API

Tasks

Task creation

To create a new task you just need to create a directory inside ./tasks/ and two files in the new created folder:

mkdir ./task/some-new-task
touch ./task/some-new-task/{config,pipeline}

config - additional configuration file for each task, which is basically used for Slack's webhooks integration, to get a messages from the task.

Example:

[slack]
webhook-url = "https://hooks.slack.com/services/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"

pipeline - a pipeline chain

Example:

export VAR1="1"; echo $VAR1
export VAR1="1"; exaport VAR2="2"; echo $VAR1 $VAR2

You don't need to reload the application after creation a task

Integration

There are a couple of http calls, which will help you to integrate it with an external systems.

API Calls:

  • To execute a task:

    /api/task/run/{taskName}?param1=var1 - API, for execution of a task, where {taskName} is a folder in tasks dir. You can use username and password from general configuration to turning on a basic authorization. CURL example to execute a task with basic auth header:

    curl -i -H 'Authorization: Basic dXNlcjo2NjY2NjY=' 'http://localhost:8080/api/task/run/test?param1=var1'
    

    param1 - is a parameter for pipeline via HTTP interface and could be used in you script(like: $param1).

    If you will configure a webhook-url for Slack, then you will be able to get a status messages from the call.

  • To integrate with Slack:

    • /api/integration/slack/list - to list available tasks;
    • /api/integration/slack/run - run task manually from Slack
    /taskrun test param1=value1;param2=value2
    

    example to execute slack pipeline with params

    to integrate this calls you need to go to the https://api.slack.com and create a new application. Then, you need to get a verification token and put it into main configuration. slack token

    the second step, will be to create a "Slash commands": one for list and another for run slash commands

    Examples:

    • taskrun taskrun

    • tasklist: taskrun

More Repositories

1

goimports-reviser

Right imports sorting & code formatting tool (goimports alternative)
Go
459
star
2

proxy-chrome-extension

Chrome plugin to setting up a proxy settings via plugin's UI or by browser's address bar
JavaScript
20
star
3

asterisk-ami-api

Call, SMS, CDR APIs for Asterisk
Go
14
star
4

gostruct2graphql

Go structure to GraphQL object
Go
12
star
5

redis-mock-template

Redis Mock (Stateful) for Java based apps & tests
Java
6
star
6

asterisk-dialer

JavaScript
5
star
7

liqueur-sensor

Firmware for water leakage sensor with low battery control based on Attiny13
C++
3
star
8

idrac

Shell
2
star
9

kafka-client

2
star
10

docker

Nginx
2
star
11

gdb

Data backup tool for MySQL databases, local files and directories to S3 or DigitalOcean Space
Go
2
star
12

pincode

Java
1
star
13

ansible-paybooks

1
star
14

BigData

Java
1
star
15

elk

ELK + logspout
Go
1
star
16

sensu-server

1
star
17

grpc-java-test

Java
1
star
18

joomla-extensions

PHP
1
star
19

cm_api_client

Java
1
star
20

flux-test

JavaScript
1
star
21

goutils

Go
1
star
22

vote-bot

telegram bot for voting based on AWS DynamoDB
Go
1
star
23

thrift-logger

Thrift log decorator library
Java
1
star
24

AMBARI

JavaScript
1
star
25

vue-dart-template

HTML
1
star
26

xml-creator

Go
1
star
27

logger

Go
1
star
28

fs-automation

Go
1
star
29

http-debug-server

Go
1
star
30

RabbitMQProducer

Go
1
star
31

nginx_modules

C
1
star
32

VIDEO_PROJECTS

Java
1
star
33

jwt-example

Go
1
star
34

homebrew-tap

Homebrew repository for different tools
Ruby
1
star
35

go-with-sonar

Dockerfile
1
star
36

cfengine-client

Java
1
star
37

ckafka

Go
1
star
38

graphQlGoTest

Go
1
star
39

openvox-sms-ui

JavaScript
1
star
40

spring-redis-tpl-example

Example of redis-mock-template usage for Medium article
Java
1
star
41

check-openvox-gsm

Tool to check GSM signal on OpenVox
Go
1
star
42

POLYCOM

Java
1
star
43

json-check

Python
1
star