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

docker-secreto

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

docker-secreto

pull docker secrets into an object

  • 1.1.1
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

docker-secreto

"Secreto" is the word for secret, in Spanish.

This provides a super simple way to pull docker secret passwords into your code.

Installation

npm i -S docker-secreto

To pull all secrets in

const dockerSecreto = require('docker-secreto')

let values = dockerSecreto()

console.info(values)
Output:
{
  secret_name: 'secret value goes here',
  another_password: 'password123' // because that's what you should use
}

To pull a specific secret

const dockerSecreto = require('docker-secreto')

let values = dockerSecreto('secret_name', 'Default Value')

console.info(values)
Output if there is a match
'secret value goes here'

If there is no matching secret

const dockerSecreto = require('docker-secreto')

let values = dockerSecreto('secret_name', 'Default Value')

console.info(values)
Output if there is not a match
'Default Value'

FAQs

Package last updated on 17 Nov 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

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