npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

hubot-graylog-adapter

v0.0.2

Published

Graylog logging adapter for Hubot

Downloads

4

Readme

hubot-graylog-adapter

npm version Build Status

Graylog logging adapter for Hubot

Installation

  • Run the npm install command
npm install hubot-graylog-adapter --save
  • Add hubot-graylog-adapter to the array in your external-scripts.json file.
[
  "hubot-graylog-adapter"
]
  • Configure environment variables

| Environment Variable | Required | Description | Example | |-----------------------------------|----------|---------------------------------------------------------|---------------------| | HUBOT_GRAYLOG_ADAPTER_HOSTNAME | Yes | Hostname/IP of Graylog server | graylog.example.com | | HUBOT_GRAYLOG_ADAPTER_PORT | no | GELF port number of Graylog server (default: 12201) | 12201 | | HUBOT_GRAYLOG_ADAPTER_FACILITY | no | 'facility' attribute for log messages (default: hubot) | hubot | | HUBOT_GRAYLOG_ADAPTER_APPNAME | no | 'app' attribute for log messages (default: hubot) | hubot | | HUBOT_GRAYLOG_ADAPTER_ENVIRONMENT | no | 'env' attribute for log messages (default: development) | development | | HUBOT_LOG_LEVEL | no | Hubot logging level (default: info) | info |

Usage

Use the robot.logger methods in your hubot scripting, and your messages will be sent to the console as well as Graylog.

  module.exports = (robot) ->
   robot.hear /knock knock/i, (msg) ->
     robot.logger.info "Someone is telling a joke!"
     msg.send "Who is there?"

Supported robot.logger levels:

robot.logger.emergency "Graylog logger!"
robot.logger.alert "Graylog logger!"
robot.logger.critical "Graylog logger!"
robot.logger.error "Graylog logger!"
robot.logger.warning "Graylog logger!"
robot.logger.notice "Graylog logger!"
robot.logger.info "Graylog logger!"
robot.logger.debug "Graylog logger!"

Tests

To run the tests, run the below command. If you are contributing, please add appropriate tests before submitting a pull request.

npm test

Acknowledgements

This project makes use of: