mirror of
https://github.com/fosrl/pangolin.git
synced 2026-06-03 06:21:32 +00:00
change logging
This commit is contained in:
@@ -121,7 +121,7 @@ export function createApiServer() {
|
|||||||
const httpServer = apiServer.listen(externalPort, (err?: any) => {
|
const httpServer = apiServer.listen(externalPort, (err?: any) => {
|
||||||
if (err) throw err;
|
if (err) throw err;
|
||||||
logger.info(
|
logger.info(
|
||||||
`API server is running on http://localhost:${externalPort}`
|
`Dashboard API server is running on http://localhost:${externalPort}`
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ export function createInternalServer() {
|
|||||||
internalServer.listen(internalPort, (err?: any) => {
|
internalServer.listen(internalPort, (err?: any) => {
|
||||||
if (err) throw err;
|
if (err) throw err;
|
||||||
logger.info(
|
logger.info(
|
||||||
`Internal server is running on http://localhost:${internalPort}`
|
`Internal API server is running on http://localhost:${internalPort}`
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -72,7 +72,7 @@ class TelemetryClient {
|
|||||||
logger.debug("Successfully sent analytics data");
|
logger.debug("Successfully sent analytics data");
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
48 * 60 * 60 * 1000
|
336 * 60 * 60 * 1000
|
||||||
);
|
);
|
||||||
|
|
||||||
this.collectAndSendAnalytics().catch((err) => {
|
this.collectAndSendAnalytics().catch((err) => {
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ export async function createNextServer() {
|
|||||||
nextServer.listen(nextPort, (err?: any) => {
|
nextServer.listen(nextPort, (err?: any) => {
|
||||||
if (err) throw err;
|
if (err) throw err;
|
||||||
logger.info(
|
logger.info(
|
||||||
`Next.js server is running on http://localhost:${nextPort}`
|
`Dashboard Web UI server is running on http://localhost:${nextPort}`
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -89,7 +89,7 @@ async function pushCertUpdateToAffectedNewts(
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.info(
|
logger.debug(
|
||||||
`acmeCertSync: pushing cert update to ${affectedResources.length} affected site resource(s) for domain "${domain}"`
|
`acmeCertSync: pushing cert update to ${affectedResources.length} affected site resource(s) for domain "${domain}"`
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -187,7 +187,7 @@ async function pushCertUpdateToAffectedNewts(
|
|||||||
newt.version
|
newt.version
|
||||||
);
|
);
|
||||||
|
|
||||||
logger.info(
|
logger.debug(
|
||||||
`acmeCertSync: pushed cert update to newt for site ${siteId}, resource ${resource.siteResourceId}`
|
`acmeCertSync: pushed cert update to newt for site ${siteId}, resource ${resource.siteResourceId}`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -400,7 +400,7 @@ async function syncAcmeCerts(
|
|||||||
})
|
})
|
||||||
.where(eq(certificates.domain, domain));
|
.where(eq(certificates.domain, domain));
|
||||||
|
|
||||||
logger.info(
|
logger.debug(
|
||||||
`acmeCertSync: updated certificate for ${domain} (expires ${expiresAt ? new Date(expiresAt * 1000).toISOString() : "unknown"})`
|
`acmeCertSync: updated certificate for ${domain} (expires ${expiresAt ? new Date(expiresAt * 1000).toISOString() : "unknown"})`
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -423,7 +423,7 @@ async function syncAcmeCerts(
|
|||||||
wildcard
|
wildcard
|
||||||
});
|
});
|
||||||
|
|
||||||
logger.info(
|
logger.debug(
|
||||||
`acmeCertSync: inserted new certificate for ${domain} (expires ${expiresAt ? new Date(expiresAt * 1000).toISOString() : "unknown"})`
|
`acmeCertSync: inserted new certificate for ${domain} (expires ${expiresAt ? new Date(expiresAt * 1000).toISOString() : "unknown"})`
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -461,7 +461,7 @@ export function initAcmeCertSync(): void {
|
|||||||
const resolver = privateConfigData.acme?.resolver ?? "letsencrypt";
|
const resolver = privateConfigData.acme?.resolver ?? "letsencrypt";
|
||||||
const intervalMs = privateConfigData.acme?.sync_interval_ms ?? 5000;
|
const intervalMs = privateConfigData.acme?.sync_interval_ms ?? 5000;
|
||||||
|
|
||||||
logger.info(
|
logger.debug(
|
||||||
`acmeCertSync: starting ACME cert sync from "${acmeJsonPath}" using resolver "${resolver}" every ${intervalMs}ms`
|
`acmeCertSync: starting ACME cert sync from "${acmeJsonPath}" using resolver "${resolver}" every ${intervalMs}ms`
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@@ -381,7 +381,7 @@ export function startPingAccumulator(): void {
|
|||||||
// Don't prevent the process from exiting
|
// Don't prevent the process from exiting
|
||||||
flushTimer.unref();
|
flushTimer.unref();
|
||||||
|
|
||||||
logger.info(
|
logger.debug(
|
||||||
`Ping accumulator started (flush interval: ${FLUSH_INTERVAL_MS}ms)`
|
`Ping accumulator started (flush interval: ${FLUSH_INTERVAL_MS}ms)`
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user