mirror of
https://github.com/R0m1k3/Apiflow-gateway.git
synced 2026-10-20 05:28:19 +02:00
feat: add data synchronization service with a web-based dashboard.
This commit is contained in:
1 parent
7ba7df7648
commit
cc69c5b886
2 files changed
+3
-3
No files matched your search
+2
-2
@@ -77,8 +77,8 @@ if (forceMode) {
|
||||
});
|
||||
} else {
|
||||
startDashboard();
|
||||
console.log('Service sync Hostinger démarré — cron: 30 3 * * * (3h30 chaque nuit)');
|
||||
cron.schedule('30 3 * * *', () => {
|
||||
console.log('Service sync Hostinger démarré — cron: 30 5 * * * (5h30 chaque nuit)');
|
||||
cron.schedule('30 5 * * *', () => {
|
||||
syncAll(false).catch(err => console.error('Erreur cron sync:', err.message));
|
||||
});
|
||||
}
|
||||
+1
-1
@@ -64,7 +64,7 @@ app.get('/api/logs', (req, res) => {
|
||||
app.get('/api/next', (req, res) => {
|
||||
const now = new Date();
|
||||
const next = new Date(now);
|
||||
next.setHours(3, 30, 0, 0);
|
||||
next.setHours(5, 30, 0, 0);
|
||||
if (next <= now) next.setDate(next.getDate() + 1);
|
||||
res.json({ next: next.toISOString() });
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user