ssm-parameters-boot
v4.1.0
Published
Edit parameters in CLI and store to aws ssm parameter store
Downloads
5
Readme
ssm-parameters-boot
Edit parameters in CLI and store to aws ssm parameter store
DEMO
Requirements
node >= 16.0
typescript >= 4.7
ts-node >= 10.8
Install
npm i ssm-parameters-boot ssm-env-client construct-typed-parameters
Setup
// cli.ts
import { bootstrap } from "../src/index.js";
import { SsmEnvClient } from "ssm-env-client";
import { TypedParameters } from "construct-typed-parameters";
const parameters = new TypedParameters((pt) => ({
TOKEN: pt.string({ required: true, defaultValue: "token" }),
FIREBASE_CONFIG: pt.json<{ apiKey: string }>({
required: true,
defaultValue: { apiKey: "apiKey" },
}),
}));
const ssmClient = new SsmEnvClient("YourServiceName");
const result = await bootstrap(parameters, ssmClient);
console.log(result);
Usage
node --loader ts-node/esm cli.ts