candymail icon indicating copy to clipboard operation
candymail copied to clipboard

Allow for "Bring your own DB"

Open bdcorps opened this issue 3 years ago • 0 comments

Currently Candymail uses an internal SQLLite DB to keep track of all the emails to be sent out. For more production use cases, we should have the option to specify an external DB.

The config object might look like:

{
    mail: {
      host: 'smtp.gmail.com',
      port: 465,
      secure: true,
      auth: {
        user: process.env.MAIL_USER,
        pass: process.env.MAIL_PASSWORD,
      },
      tls: {
        rejectUnauthorized: true,
      },
    },
    hosting: { url: process.env.HOSTING_URL },
    db: { url: "SQLITE_URL", reset: true },
    debug: { trace: true },
  }

bdcorps avatar May 25 '22 13:05 bdcorps