Compare commits

...

4 Commits

Author SHA1 Message Date
3151829f85 2.0.31 2019-01-16 22:34:38 +01:00
eca63e588c fix(core): update 2019-01-16 22:34:38 +01:00
9d23e205d8 2.0.30 2019-01-16 02:34:48 +01:00
5ecdf7c9fd fix(core): update 2019-01-16 02:34:47 +01:00
6 changed files with 6 additions and 4 deletions

2
package-lock.json generated
View File

@ -1,6 +1,6 @@
{
"name": "@pushrocks/smartacme",
"version": "2.0.29",
"version": "2.0.31",
"lockfileVersion": 1,
"requires": true,
"dependencies": {

View File

@ -1,6 +1,6 @@
{
"name": "@pushrocks/smartacme",
"version": "2.0.29",
"version": "2.0.31",
"private": false,
"description": "acme implementation in TypeScript",
"main": "dist/index.js",

View File

@ -1,6 +1,7 @@
export type TCertStatus = 'existing' | 'nonexisting' | 'pending' | 'failed';
export interface ICert {
id: string;
domainName: string;
created: number;
privateKey: string;

View File

@ -12,7 +12,7 @@ import { ICert } from './interfaces';
})
export class Cert extends plugins.smartdata.SmartDataDbDoc<Cert> implements interfaces.ICert {
@unI()
public index: string;
public id: string;
@svDb()
public domainName: string;

View File

@ -86,7 +86,7 @@ export class CertManager {
}
// otherwise lets continue
const existingCertificate = this.retrieveCertificate(certDomainArg);
const existingCertificate = await this.retrieveCertificate(certDomainArg);
if (existingCertificate) {
return 'existing';
}

View File

@ -194,6 +194,7 @@ export class SmartAcme {
console.log(`Certificate:\n${cert.toString()}`);
await this.certmanager.storeCertificate({
id: plugins.smartunique.shortId(),
domainName: certDomain,
privateKey: key.toString(),
publicKey: cert.toString(),