Skip to content

Commit 486cbfc

Browse files
authored
wp-config tweaks to decrease burden sqlite file (#86)
1 parent 48a6068 commit 486cbfc

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

wp/wp-config.php

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,11 +124,17 @@
124124
define('DB_FILE', 'wp-sqlite-s3.sqlite');
125125
}
126126

127-
// Auto-cron is can cause db race conditions on these urls, don't bother with it.
127+
// Auto-cron can cause db race conditions on these urls, don't bother with it.
128128
if (strpos($_SERVER['REQUEST_URI'], 'wp-admin') !== false || strpos($_SERVER['REQUEST_URI'], 'wp-login') !== false) {
129129
define('DISABLE_WP_CRON', true);
130130
}
131131

132+
// Increase time between cron runs (2 hours) to reduce DB writes.
133+
define('WP_CRON_LOCK_TIMEOUT', 7200);
134+
135+
// Limit revisions.
136+
define('WP_POST_REVISIONS', 3);
137+
132138
/* That's all, stop editing! Happy publishing. */
133139

134140
/** Absolute path to the WordPress directory. */

0 commit comments

Comments
 (0)