Closed jangrewe closed 9 months ago
The only unlink
used in the server code is here:
// @ts-ignore
stream.on("end", async () => {
await this.filter("Data", session, [session]);
session.email = await simpleParser(fs.createReadStream(session.emailPath));
await this.onDataRead(session);
if (!this.config.keepCache) {
fs.unlinkSync(session.emailPath);
}
callback();
});
I'm still unsure why it cannot delete it, I will update code to have a try/catch around the unlink today, in the mean time you can try to add a keepCache: true
to your configuration
Thanks, i've added this to the config and will keep an eye on the log and any updates. 😃
The 1.3.3 version should not have the issue, please keep me update, and if you like the project please star it. It helps with visibility
Thank you! I've just deployed the updated image and now i'm waiting for the first error (without crash), but i'm confident that your changes will be doing what they're supposed to. 😀
Describe the bug We're running
smtp-relay
in Docker on an EC2 instance, and the container regularly crash with this error (but varying filenames, of course):The majority of mail it accepts gets handled without any issues, but this happens every once in a while (e.g. twice in 12 hours now).
To Reproduce Steps to reproduce the behavior:
smtp-relay
Expected behavior Emails get relayed and the container keeps running.