try to commit

This commit is contained in:
2026-07-14 12:34:40 +08:00
parent 17755fce7e
commit a7a72096a5
6 changed files with 167 additions and 61 deletions
+8 -8
View File
@@ -20,7 +20,7 @@
* ✓ database — PostgreSQL via Sequelize (CRITICAL)
* ✓ cache — Redis PING; skipped in memory mode (optional)
* ✓ storage — S3/Garage HeadBucket (optional)
* ✓ smtp — Nodemailer connection verify (optional)
* ✓ email — Gmail API profile fetch (OAuth2) (optional)
*
* Checks intentionally excluded:
* ✗ chibisafe — third-party CDN; not owned infrastructure
@@ -35,8 +35,8 @@ const os = require('os');
const sequelize = require('../config/db.config');
const redis = require('../config/redis.config');
const { ping: pingS3 } = require('./s3.service');
const { ping: pingSmtp } = require('./email.service');
const { ping: pingS3 } = require('./s3.service');
const { ping: pingEmail } = require('./email.service');
const PKG = require('../package.json');
const TIMEOUT_MS = 3000;
@@ -85,12 +85,12 @@ const CHECKS = [
run: pingS3,
},
{
name: 'smtp',
name: 'email',
critical: false,
enabled: !!process.env.SMTP_HOST,
skipNote: 'SMTP_HOST is not configured',
meta: { host: process.env.SMTP_HOST, port: Number(process.env.SMTP_PORT) || 587 },
run: pingSmtp,
enabled: !!(process.env.GOOGLE_CLIENT_ID && process.env.GMAIL_REFRESH_TOKEN),
skipNote: 'GMAIL_REFRESH_TOKEN is not configured',
meta: { provider: 'gmail-api', account: process.env.EMAIL_FROM },
run: pingEmail,
},
];