fix(ci): fix build-time nodemailer connection error and next.config warning
Some checks failed
Some checks failed
This commit is contained in:
@@ -54,4 +54,11 @@ const withMDX = createMDX({});
|
|||||||
|
|
||||||
// Clean, standard wrapper application
|
// Clean, standard wrapper application
|
||||||
// Rewrites are now handled by src/middleware.ts for maximum robustness
|
// Rewrites are now handled by src/middleware.ts for maximum robustness
|
||||||
export default withPayload(withMintelConfig(withMDX(nextConfig)));
|
const config = withMintelConfig(withMDX(nextConfig));
|
||||||
|
|
||||||
|
// Cleanup config to prevent Next.js 16 warnings about deprecated keys
|
||||||
|
if (config.serverActions) {
|
||||||
|
delete config.serverActions;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default withPayload(config);
|
||||||
|
|||||||
@@ -28,7 +28,8 @@ const dirname = path.dirname(filename);
|
|||||||
|
|
||||||
const isCLI =
|
const isCLI =
|
||||||
process.argv.includes("migrate") ||
|
process.argv.includes("migrate") ||
|
||||||
process.argv.includes("generate:importmap");
|
process.argv.includes("generate:importmap") ||
|
||||||
|
process.argv.includes("build");
|
||||||
let aiPlugin: any;
|
let aiPlugin: any;
|
||||||
if (!isCLI) {
|
if (!isCLI) {
|
||||||
const { payloadChatPlugin } = await import("@mintel/payload-ai");
|
const { payloadChatPlugin } = await import("@mintel/payload-ai");
|
||||||
@@ -67,19 +68,21 @@ export default buildConfig({
|
|||||||
globals: [
|
globals: [
|
||||||
/* AiSettings as any */
|
/* AiSettings as any */
|
||||||
],
|
],
|
||||||
email: nodemailerAdapter({
|
email: isCLI
|
||||||
defaultFromAddress: process.env.MAIL_FROM || "info@mintel.me",
|
? undefined
|
||||||
defaultFromName: "Mintel.me",
|
: nodemailerAdapter({
|
||||||
transportOptions: {
|
defaultFromAddress: process.env.MAIL_FROM || "info@mintel.me",
|
||||||
host: process.env.MAIL_HOST || "localhost",
|
defaultFromName: "Mintel.me",
|
||||||
port: parseInt(process.env.MAIL_PORT || "587", 10),
|
transportOptions: {
|
||||||
auth: {
|
host: process.env.MAIL_HOST || "localhost",
|
||||||
user: process.env.MAIL_USERNAME || "user",
|
port: parseInt(process.env.MAIL_PORT || "587", 10),
|
||||||
pass: process.env.MAIL_PASSWORD || "pass",
|
auth: {
|
||||||
},
|
user: process.env.MAIL_USERNAME || "user",
|
||||||
...(process.env.MAIL_HOST ? {} : { ignoreTLS: true }),
|
pass: process.env.MAIL_PASSWORD || "pass",
|
||||||
},
|
},
|
||||||
}),
|
...(process.env.MAIL_HOST ? {} : { ignoreTLS: true }),
|
||||||
|
},
|
||||||
|
}),
|
||||||
editor: lexicalEditor({
|
editor: lexicalEditor({
|
||||||
features: ({ defaultFeatures }) => [
|
features: ({ defaultFeatures }) => [
|
||||||
...defaultFeatures,
|
...defaultFeatures,
|
||||||
|
|||||||
Reference in New Issue
Block a user