Coder Social home page Coder Social logo

vandro / debugchannel-tail-client Goto Github PK

View Code? Open in Web Editor NEW

This project forked from debugchannel/debugchannel-tail-client

0.0 1.0 0.0 188 KB

Tail Client For DebugChannel

Home Page: www.debugchannel.com

License: GNU Affero General Public License v3.0

debugchannel-tail-client's Introduction

debugchannel-tail-client

A simple command line tool that can tail multiple files and publish the output to debugchannels. This can be used for tailing mysql slow queries log, apache error logs or infact any log file which is related to your software development.

Install

Execute the install.sh script (as root) which will add dctail to /usr/local/bin/ and generates a configuration file /etc/debugchannel/dctail.conf.

sudo ./install.sh

The script also installs a bash script in /etc/init.d/detail so that you can run dctail as a service by running:

service dctail start

You can configure dctail to run at startup by running:

sudo update-rc.d dctail defaults

Configuration

The configuration file /etc/debugchannel/dctail.conf is generated during the install process. The permission on the configuration file is set to 644 which allows the file to be read by any user but it can only be written by root. This file has the following json format:

{
    "address": "https://debugchannel.com",
    "apiKey": "someApiKey",
    "files": {"/var/log/mylog.txt": "nameofchannel"}
}

address: (required) server address of debugchannel.

apiKey: (optional) set if your debugchannel supports authentication (only available on enterprise debugchannels)

files: (optional) maps files to debugchannels. If you do not set a list of file in the configuration file then you will need to specify them when you run dctail from the command line.

Example Usage

If you have specified a list of files in dctail.conf then you simple run:

   dctail

If you have not specified any files in dctail.conf then you can specify file the files in the command line:

    dctail mylog.txt:mylogchannel serverlog.txt:serverlogchannel

This will tail 2 files: mylog.txt and serverlog.txt and publish the results to the channels logchannel and serverlogchannel respectively.

You can specify files in both the dctail.conf and as command line options and both will be used. However, if there is conflict the command line arguments will overright the configuration specifed in the file.

If you have damaged your configuration file then you can run

    dctail --setup

This creates the /etc/debugchannel/dctail.conf config file from defaults and then exits.

debugchannel-tail-client's People

Contributors

jamestuthill avatar commander-joseph avatar

Watchers

Vandro Neves dos Santos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.