WP Manifestindependent plugin directory
manifest / developer / wp-cron-runner

Cron Runner

WP Cron Runner - A simple mu-plugin to run cron jobs on WordPress installations

★ 4stars
1.0.3latest · 7 years ago

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/devgeniem/wp-cron-runner/archive/refs/heads/master.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

geniem-github-banner

WP Cron Runner

Latest Stable Version Total Downloads Latest Unstable Version License

This simple mu-plugin lets you run WordPress cron jobs for a site or all network sites via a single endpoint. This is useful when building a single solution to run WP cron jobs on a hosting platform for different type of WordPress installations.

Installation

Install the plugin with Composer. It requires the Bedrock mu-plugins autoloader.

composer require devgeniem/wp-cron-runner

Or install the plugin manually by copying the plugin.php under your mu-plugin directory and renaming it to wp-cron-runner.php.

Usage

This plugin defines a single endpoint to run WP crons.

http(s)://www.mysite.com/run-cron

On a network installation you only need to request a single site. The plugin will fetch all active sites from the database and call the /wp-cron.php endpoint to run scheduled events.

To enable timed execution create a cronjob to make a HTTP request to the /run-cron endpoint. To test if the plugin is functioning, request the endpoint on a browser to see a list of sites the cron was executed for.

The plugin will exit WordPress execution after a successful request to the endpoint. This will minimize the server load since the plugin code is run when mu-plugins are loaded.

Basic auth

If you are using basic authentication define these constants.

// Username
define( 'WP_CRON_RUNNER_AUTH_USER', 'username' );
// Password
define( 'WP_CRON_RUNNER_AUTH_PW', 'pw' );

Alternatively you can also use BASIC_AUTH_USER, BASIC_AUTH_PASSWORD and BASIC_AUTH_PASSWORD_HASH constants. When using the latter "{PLAIN}" is removed from the password string.

Maintainers

@villesiltala @villepietarinen

License

GPLv3

Releases

2 releases.

Tag
Published
1.0.3 latest
Dec 3, 2018 7 years ago
Nov 16, 2017 8 years ago

These releases are tags only. The author does not attach a packaged zip, so there are no download counts to report.