Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

bristol-config

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bristol-config

Integration for Bristol logging and node-config configuration.

  • 0.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

bristol-config

Adds node-config compatibility for Bristol logging. Not all features from Bristol are reproduced in the configuration. Currently excluded are:

  • Transforms link
  • Global values link
  • Excluding/including message filters link

If you need any of these features implemented, please open an issue, submit a pull request, or get in contact with me.

Installation
npm install bristol-config
npm install bristol

Note that bristol 0.3.x is a peer dependency of bristol-config and must be installed in your project for everything to work. If you're using an older version of npm, then bristol may be installed automatically. Otherwise you'll receive an npm notification indicating that you have a missing peer dependency.

Example

Sample node-config configuration:

{
  "logging": {
    "severity": "debug",
    "targets": [
      {
        "type": "console"
      },
      {
        "severity": "error",
        "type": {
          "name": "file",
          "options": {
            "file": "/var/log/bitscoop/metric-server.log"
          }
        }
      },
      {
         "severity": "info",
         "type": {
           "module": "my-target-module-constructor",
           "options": {
             "option": "value"
           }
         }
      },
      {
        "type": {
          "module": "my-target-module-function",
          "constructor": false,
          "options": {
            "option": "value"
          }
        }
      }
    ]
}

Usage:

var bristolConf = require('bristol-config');
var config = require('config'); // Requires node-config to function as indicated.

logger = bristolConf(config.logging);

FAQs

Package last updated on 18 Apr 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc