New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

getsecret

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

getsecret

a simple api for retrieving secrets stored in yaml files and environment variables

latest
Source
npmnpm
Version
1.0.2
Version published
Maintainers
1
Created
Source

getsecret

A simple way to get credentials stored in yaml files and environment variables

Install

npm install getsecret

Storing secrets

You can store secrets in 3 locations (in decreasing order of priority)

  • An environment variable. These are commonly used in Heroku. ex: process.env.some_keyname

  • A file named .getsecret.yaml in your current directory

  • A file named .getsecret.yaml in your home directory. The format should map key names to secrets, ie:

    some_keyname: some_secret_value another_keyname: another_secret_value

Accessing secrets from code

Simply pass the key name to getsecret and its value will be returned. ex:

var getsecret = require('getsecret')
var secret_value = getsecret('some_keyname')

Author

Geza Kovacs

License

MIT

Keywords

secrets

FAQs

Package last updated on 30 Jan 2017

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