Skip to content

old paths from audit file are being created in installation directory #398

Open
@emcodem

Description

@emcodem

So the problem is that after moving the whole installation, there are unexpectedly folders created in the new root of my executable (i use nexe to compile/redistribute the project). I was a little surprised that it can create folders actually just because it searches for files mentioned in audit files, shouldnt non existing files just be ignored?

E.g. program was first int \\serverA\share\folder, audit was a subfolder /logs/audit
Move to \\ServerB\share\folder (without deleting the audit files)

After starting the program from the new install dir, strangely we get a sub folder created:
\serverA\share\folder\ServerB\share\folder...

This is about how i set up DailyRotate:

	let dailyFileTransport = new winston.transports.DailyRotateFile({
		level: 'debug',
		filename: path.join( path.dirname(process.execPath), label + "-%DATE%.log"),
		auditFile: path.join( path.dirname(process.execPath),"audit", label),
		datePattern: 'YYYY-MM-DD',
		zippedArchive: true,
		maxSize: '50m',
		maxFiles: '14d'
	  });

Original Code:
https://github.com/emcodem/ffastrans_webui/blob/master/shared_modules/logger.js

Here the original users problem report:
https://ffastrans.com/frm/forum/viewtopic.php?p=9412#p9412

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions