We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi. I have an issue with using multiple user and pass for auth in transport parameter in mailer module.
@Global() @Module({ imports: [ MailerModule.forRootAsync({ inject: [ConfigService], useFactory: (configService: ConfigService) => { const MAIL_HOST = configService.get('MAIL_HOST'); const MAIL_PORT = configService.get('MAIL_PORT'); const EXPERT_MAIL_USER = configService.get('EXPERT_MAIL_USER'); const EXPERT_MAIL_PASSWORD = configService.get('EXPERT_MAIL_PASSWORD'); const path = require('path'); const templateDir = path.join(process.cwd(), 'email-templates'); return { transport: { host: 'smtp.gmail.com', port: MAIL_PORT, secure: true, auth: { user: EXPERT_MAIL_USER, pass: EXPERT_MAIL_PASSWORD }, // tls: { rejectUnauthorized: true }, }, defaults: { from: '"Aspedan Expert" <[email protected]>', }, template: { dir: templateDir, adapter: new HandlebarsAdapter(), options: { strict: true }, }, }; }, }), ], providers: [EmailService], exports: [MailerModule, EmailService], }) export class EmailModule {}
this is my code and I need to use different values as user and pass for auth. how can I handle this ?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hi.
I have an issue with using multiple user and pass for auth in transport parameter in mailer module.
this is my code and I need to use different values as user and pass for auth.
how can I handle this ?
The text was updated successfully, but these errors were encountered: