Title: Cron site generation
Last modified: May 26, 2021

---

# Cron site generation

 *  Resolved [douglaskastle](https://wordpress.org/support/users/douglaskastle/)
 * (@douglaskastle)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/cron-site-generation/)
 * I haven’t seen this covered in the support, so apologies if this has come up (
   many) times before.
 * I would like to have a private hidden wordpress install where I configure a website
   and then have the static dump of that site be the only public facing site. It
   would be nice if the site generation could have by default, maybe if there is
   a change to the database, or even just once a day or an hour.
 * Is is possible to kick off the static site generation from command line, or setup
   a crontab to do it? How about adding a cron feature into the plugin in itself?

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Thread Starter [douglaskastle](https://wordpress.org/support/users/douglaskastle/)
 * (@douglaskastle)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/cron-site-generation/#post-14484634)
 * Maybe some of the features would become available if wp-cli support was added,
   which is being requested over here:
 * [https://patrickposner.dev/feature-requests/wp-cli-support/](https://patrickposner.dev/feature-requests/wp-cli-support/)
 * However, being able to set it up through the plugin interface would be ideal
 *  [cusmin](https://wordpress.org/support/users/cusmin/)
 * (@cusmin)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/cron-site-generation/#post-14484877)
 * You can trigger wp-cli cron job like this:
 *     ```
       wp cron event schedule simply_static_site_export_cron
       wp cron event run --due-now
       ```
   
    -  This reply was modified 4 years, 11 months ago by [cusmin](https://wordpress.org/support/users/cusmin/).
 *  Thread Starter [douglaskastle](https://wordpress.org/support/users/douglaskastle/)
 * (@douglaskastle)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/cron-site-generation/#post-14484971)
 * [@cusmin](https://wordpress.org/support/users/cusmin/)
 * Interesting, that is very helpful!
 * How does that work for multi-site? (Do you know?)
 *  Thread Starter [douglaskastle](https://wordpress.org/support/users/douglaskastle/)
 * (@douglaskastle)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/cron-site-generation/#post-14485006)
 * [@cusmin](https://wordpress.org/support/users/cusmin/)
 * I had a read about wp cron support for multi-site, this seems to work:
 *     ```
       wp cron event schedule simply_static_site_export_cron --url=example.com
       wp cron event run --due-now --url=example.com
       ```
   
 *  Thread Starter [douglaskastle](https://wordpress.org/support/users/douglaskastle/)
 * (@douglaskastle)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/cron-site-generation/#post-14485420)
 * OK that seemed to be the all i needed to solve my problem.
 * There is a plugin called WP Control (there are other ones too but that is the
   one I used), it allowed me to set up the WP cron task from the dashboard. What
   I was missing was the “Hook Name”, which is what you gave me in your reply, `
   simply_static_site_export_cron`.
 * This give me the cron like operation I was looking for.
 * WP Control also provides the ability to define time and periodicity of the job.
 * I recommend you add some of this detail, mainly the hook name, to some of the
   documentation for Simply Static.
    -  This reply was modified 4 years, 11 months ago by [douglaskastle](https://wordpress.org/support/users/douglaskastle/).
 *  Plugin Author [patrickposner](https://wordpress.org/support/users/patrickposner/)
 * (@patrickposner)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/cron-site-generation/#post-14485707)
 * Hey [@douglaskastle](https://wordpress.org/support/users/douglaskastle/),
 * thanks for the suggestions!
 * As I’m working on complete documentation of Simply Static, I add a note for this
   as well!
 * Best regards,
    Patrick

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Cron site generation’ is closed to new replies.

 * ![](https://ps.w.org/simply-static/assets/icon-256x256.png?rev=2443263)
 * [Simply Static - The Static Site Generator](https://wordpress.org/plugins/simply-static/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/simply-static/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/simply-static/)
 * [Active Topics](https://wordpress.org/support/plugin/simply-static/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/simply-static/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/simply-static/reviews/)

 * 6 replies
 * 3 participants
 * Last reply from: [patrickposner](https://wordpress.org/support/users/patrickposner/)
 * Last activity: [4 years, 11 months ago](https://wordpress.org/support/topic/cron-site-generation/#post-14485707)
 * Status: resolved