# @tryghost/greenlock-fastly-store

> [Greenlock](https://git.rootprojects.org/root/greenlock.js) stores are used by Greenlock to persist certificates, private keys and ACME accounts. This store acts as an intermediary, uploading new private keys and certificates to [Fastly](https://www.fastl

Latest version **0.1.4** (published 2021-05-05) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install @tryghost/greenlock-fastly-store
pnpm add @tryghost/greenlock-fastly-store
yarn add @tryghost/greenlock-fastly-store
bun add @tryghost/greenlock-fastly-store
```

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 0.1.4 |
| Published | 2021-05-05 |
| First published | 2021-04-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 7.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Ghost Foundation |
| Maintainers | zimoatghost, allouis, gargol, rishabhgrg, erisds, johnonolan, kevinansfield, cobbspur, aileencgn, jloh, daniellockyer, sam-lord, matthanley, thibpat, pauladamdavis |

## Links

- npm: https://www.npmjs.com/package/@tryghost/greenlock-fastly-store
- Repository: git@github.com:TryGhost/greenlock-fastly-store
- npm.io page: https://npm.io/package/@tryghost/greenlock-fastly-store

## Dependencies (1)

- [@tryghost/fastly-js](https://npm.io/package/@tryghost/fastly-js.md) ^0.2.5

## Recent versions

- 0.1.4 (latest) — 2021-05-05
- 0.1.3 — 2021-05-04
- 0.1.2 — 2021-04-14
- 0.1.1 — 2021-04-14
- 0.1.0 — 2021-04-14

## README

# Greenlock Fastly Store

[Greenlock](https://git.rootprojects.org/root/greenlock.js) stores are used by Greenlock to persist certificates, private keys and ACME accounts. This store acts as an intermediary, uploading new private keys and certificates to [Fastly](https://www.fastly.com) using their [Platform TLS API](https://developer.fastly.com/reference/api/tls/platform/) before passing the information on to a traditional store to persist the data.

The persistent data store can be configured at runtime, with existing libraries available for [file-based](https://git.rootprojects.org/root/greenlock-store-fs.js) and [database](https://git.rootprojects.org/root/greenlock-store-sequelize.js) storage.

This library is made to be used in Greenlock with configuration that looks something like this:

```json
{
    ...
    "store": {
        "module": "@tryghost/greenlock-fastly-store",
        "fastly": {
            "apiKey": "API_KEY_HERE",
            "tlsConfigurationName": "TLS v1.3",
            "allowUntrustedRoot": false
        },
        "persistentStore": {
            "module": "greenlock-store-fs",
            "basePath": "~/.greenlock.d/"
        }
    },
    ...
}
```

## Install

`npm install @tryghost/greenlock-fastly-store --save`

or

`yarn add @tryghost/greenlock-fastly-store`


## Usage

Use within Greenlock by calling `Greenlock#manager.defaults()` with the store set using the example above as a template.

## Develop

1. `git clone` this repo & `cd` into it as usual
2. Run `yarn` to install top-level dependencies.

## Run

- `yarn dev`


## Test

Tests will be implemented using the Greenlock store [test suite](https://git.rootprojects.org/root/greenlock-store-test.js).

As the store is incredibly simple, it has been possible to test using a simple Greenlock configuration.

- `yarn lint` run just eslint
- `yarn test` run lint and tests


## Publish

- `yarn ship`

# Copyright & License

Copyright (c) 2013-2021 Ghost Foundation - Released under the [MIT license](LICENSE).

---
_Source: https://npm.io/package/@tryghost/greenlock-fastly-store · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
