šŸš€ Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more →
Socket
Book a DemoInstallSign in
Socket

le-store-certbot

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

le-store-certbot

The "certbot" storage strategy for Greenlock.js

2.2.4
latest
npm
Version published
Weekly downloads
9.6K
2.68%
Maintainers
1
Weekly downloads
Ā 
Created
Source

Deprecated

le-store-certbot has been replaced with le-store-fs.

The new storage strategy keeps file system compatibility, but drops support for Python config files.

Unless you're running certbot and Greenlock side-by-side, or interchangeably, you switch to le-store-fs.

Migrating to le-store-fs

It's painless and all of your existing certificates will be preserved (assuming you use the same configDir as before).

Greenlock.create({

  // Leave configDir as it, if you've been setting it yourself.
  // Otherwise you should explicitly set it to the previous default:
  configDir: '~/letsencrypt/etc'

  // le-store-fs takes the same options as le-store-certbot,
  // but ignores some of the ones that aren't important.
, store: require('le-store-fs').create({})

  ...
})

Alternatives

  • Search npm for "le-store-" to find many alternatives.

le-store-certbot

The "certbot" storage strategy for Greenlock.js.

This le storage strategy aims to maintain compatibility with the configuration files and file structure of the official certbot client.

Note: You cannot use this strategy on ephemeral instances (heroku, aws elastic).

Usage

npm install --save le-store-certbot@2.x
var leStore = require('le-store-certbot').create({
  configDir: require('homedir')() + '/acme/etc'          // or /etc/acme or wherever
, privkeyPath: ':configDir/live/:hostname/privkey.pem'          //
, fullchainPath: ':configDir/live/:hostname/fullchain.pem'      // Note: both that :configDir and :hostname
, certPath: ':configDir/live/:hostname/cert.pem'                //       will be templated as expected by
, chainPath: ':configDir/live/:hostname/chain.pem'              //       greenlock.js

, logsDir: require('homedir')() + '/tmp/acme/log'

, webrootPath: '~/acme/srv/www/:hostname/.well-known/acme-challenge'

, debug: false
});

The store module can be used globally with Greenlock like this:

var Greenlock = require('greenlock');

Greenlock.create({
  ...
, store: leStore
});

Example File Structure

~/acme/
└── etc
    ā”œā”€ā”€ accounts
    │   └── acme-staging.api.letsencrypt.org
    │       └── directory
    │           └── cd96ac4889ddfa47bfc66300ab223342
    │               ā”œā”€ā”€ meta.json
    │               ā”œā”€ā”€ private_key.json
    │               └── regr.json
    ā”œā”€ā”€ archive
    │   └── example.com
    │       ā”œā”€ā”€ cert0.pem
    │       ā”œā”€ā”€ chain0.pem
    │       ā”œā”€ā”€ fullchain0.pem
    │       └── privkey0.pem
    ā”œā”€ā”€ live
    │   └── example.com
    │       ā”œā”€ā”€ cert.pem
    │       ā”œā”€ā”€ chain.pem
    │       ā”œā”€ā”€ fullchain.pem
    │       ā”œā”€ā”€ privkey.pem
    │       └── privkey.pem.bak
    └── renewal
        ā”œā”€ā”€ example.com.conf
        └── example.com.conf.bak

Keywords

le-store

FAQs

Package last updated on 13 May 2024

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