mirror of
https://github.com/HeyPuter/puter.git
synced 2026-05-03 16:10:31 +00:00
devex: reduce logs at init
Moves more logs to debug level, removing a few that were unnecessary.
This commit is contained in:
@@ -323,7 +323,7 @@ module.exports = class FSNodeContext {
|
||||
},
|
||||
};
|
||||
|
||||
this.log.info('fetching entry: ' + this.selector.describe());
|
||||
this.log.debug('fetching entry: ' + this.selector.describe());
|
||||
|
||||
const entry = await this.provider.stat({
|
||||
selector: this.selector,
|
||||
|
||||
@@ -71,7 +71,7 @@ class CaptchaService extends BaseService {
|
||||
*/
|
||||
async _init() {
|
||||
if (!this.enabled) {
|
||||
this.log.info('Captcha service is disabled');
|
||||
this.log.debug('Captcha service is disabled');
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -328,7 +328,7 @@ class CaptchaService extends BaseService {
|
||||
});
|
||||
|
||||
this.endpointsRegistered = true;
|
||||
this.log.info('Captcha service endpoints registered successfully');
|
||||
this.log.debug('Captcha service endpoints registered successfully');
|
||||
|
||||
// Emit an event that captcha service is ready
|
||||
try {
|
||||
|
||||
@@ -524,7 +524,8 @@ class LogService extends BaseService {
|
||||
}
|
||||
|
||||
this.log = this.create('log-service');
|
||||
this.log.system('log service started', {
|
||||
this.log.system('log service started');
|
||||
this.log.debug('log service configuration', {
|
||||
output_lvl: this.output_lvl,
|
||||
log_directory: this.log_directory,
|
||||
});
|
||||
|
||||
@@ -106,7 +106,7 @@ class ServerHealthService extends BaseService {
|
||||
mem_total: meminfo.MemTotal,
|
||||
};
|
||||
|
||||
this.log.info('memory', log_fields);
|
||||
this.log.debug('memory', log_fields);
|
||||
|
||||
Object.assign(this.stats_, log_fields);
|
||||
|
||||
|
||||
@@ -72,7 +72,7 @@ class DNSService extends BaseService {
|
||||
});
|
||||
|
||||
server.on('listening', () => {
|
||||
this.log.info('Fake DNS server listening', server.addresses());
|
||||
this.log.debug('Fake DNS server listening', server.addresses());
|
||||
|
||||
if ( this.config.test_server_selftest ) (async () => {
|
||||
await sleep(5000);
|
||||
|
||||
@@ -2,7 +2,7 @@ const BaseService = require("../../services/BaseService");
|
||||
|
||||
class TestConfigReadService extends BaseService {
|
||||
async _init () {
|
||||
this.log.noticeme('test config value (should be abcdefg) is: ' +
|
||||
this.log.debug('test config value (should be abcdefg) is: ' +
|
||||
this.global_config.testConfigValue,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -86,7 +86,7 @@ class WebServerService extends BaseService {
|
||||
return res.sendStatus(200);
|
||||
});
|
||||
|
||||
this.log.noticeme('web server setup done');
|
||||
this.log.debug('web server setup done');
|
||||
}
|
||||
|
||||
install_post_middlewares_ ({ app }) {
|
||||
@@ -168,7 +168,7 @@ class WebServerService extends BaseService {
|
||||
for ( let i = 0 ; i < ports_to_try.length ; i++ ) {
|
||||
const port = ports_to_try[i];
|
||||
const is_last_port = i === ports_to_try.length - 1;
|
||||
if ( auto_port ) this.log.info('trying port: ' + port);
|
||||
if ( auto_port ) this.log.debug('trying port: ' + port);
|
||||
try {
|
||||
server = http.createServer(this.app).listen(port);
|
||||
server.timeout = 1000 * 60 * 60 * 2; // 2 hours
|
||||
|
||||
@@ -216,7 +216,7 @@ class Container {
|
||||
*/
|
||||
async emit (id, ...args) {
|
||||
if ( this.logger ) {
|
||||
this.logger.info(`services:event ${id}`, { args });
|
||||
this.logger.debug(`services:event ${id}`, { args });
|
||||
}
|
||||
|
||||
const promises = [];
|
||||
|
||||
@@ -179,7 +179,7 @@ class PermissionService extends BaseService {
|
||||
}
|
||||
async #scan(actor, permission_options, _reserved, state) {
|
||||
if ( ! state ) {
|
||||
this.log.info('scan', {
|
||||
this.log.debug('scan', {
|
||||
actor: actor.uid,
|
||||
permission_options,
|
||||
});
|
||||
|
||||
@@ -467,7 +467,7 @@ class DriverService extends BaseService {
|
||||
|
||||
effective_policy = effective_policy.policy;
|
||||
|
||||
this.log.info('Invoking Driver Call', {
|
||||
this.log.debug('Invoking Driver Call', {
|
||||
service_name,
|
||||
iface,
|
||||
method,
|
||||
|
||||
@@ -34,7 +34,7 @@ module.exports = async (options = {}) => {
|
||||
const entries = [];
|
||||
|
||||
for ( const extensionsDir of extension_directories ) {
|
||||
console.log(`Reading extensions from ${extensionsDir}`);
|
||||
// console.log(`Reading extensions from ${extensionsDir}`);
|
||||
// Read and process extension entries from the extensions directory
|
||||
const readdir_entries = fs.readdirSync(extensionsDir, { withFileTypes: true })
|
||||
for ( const entry of readdir_entries ) {
|
||||
|
||||
Reference in New Issue
Block a user