Fixed issue with cert renew
This commit is contained in:
@@ -17,7 +17,9 @@ module.exports = {
|
|||||||
},
|
},
|
||||||
service:{
|
service:{
|
||||||
hostScheduler:{
|
hostScheduler:{
|
||||||
enabled: false,
|
enabled: true,
|
||||||
|
initial: 5000,
|
||||||
|
interval: 86400000,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -235,7 +235,6 @@ class Host extends Table{
|
|||||||
|
|
||||||
async checkWildcardForRenew(){
|
async checkWildcardForRenew(){
|
||||||
try{
|
try{
|
||||||
console.log(`Checking ${this.host}`);
|
|
||||||
if(this.is_wildcard && Date.now() > this.wildcard_expires - (30 * 24 * 60 * 60 * 1000)){
|
if(this.is_wildcard && Date.now() > this.wildcard_expires - (30 * 24 * 60 * 60 * 1000)){
|
||||||
this.createWildcardCert();
|
this.createWildcardCert();
|
||||||
}
|
}
|
||||||
@@ -247,9 +246,8 @@ class Host extends Table{
|
|||||||
|
|
||||||
static async checkWildcardForRenew(){
|
static async checkWildcardForRenew(){
|
||||||
try{
|
try{
|
||||||
console.log('checkWildcardForRenew here', this)
|
|
||||||
for(let host of await this.listDetail()){
|
for(let host of await this.listDetail()){
|
||||||
host.createWildcardCert();
|
host.checkWildcardForRenew();
|
||||||
}
|
}
|
||||||
}catch(error){
|
}catch(error){
|
||||||
console.error('checkWildcardForRenew', error)
|
console.error('checkWildcardForRenew', error)
|
||||||
|
|||||||
Reference in New Issue
Block a user