Linux 软件免费装
Banner图

Stillgate — Editorial Freeze for Deployments

开发者 twelvell
更新时间 2026年10月20日 01:34
PHP版本: 8.1 及以上
WordPress版本: 7.1
版权: GPLv2 or later
版权网址: 版权信息

标签

migration maintenance wp-cli deployment freeze

下载

0.1.1 0.2.0

详情介绍:

Deploying a WordPress site — syncing a database, pushing files, running a migration — usually needs a window where the database will not change underneath you. In practice, editors keep working, and a post, upload or menu change made mid-sync can be silently lost. Stillgate puts the backend into a controlled editorial freeze for exactly that window, while the public site keeps working normally the whole time. It ends by itself, and afterwards it tells you whether anything changed. What you get A freeze in practice wp stillgate enable --for=30m --message="Deploying release 42, back shortly." ... sync files and database ... wp stillgate receipt --check wp stillgate disable The same operations are one click on Tools > Stillgate. What a freeze protects While active, a logged-in user without the deployment_guard_bypass capability cannot create, edit, delete or restore protected content — posts, pages, custom post types, media, revisions, taxonomies and terms, navigation menus, widgets, or the Customizer — through classic wp-admin, the block editor, the REST API and XML-RPC. WP-CLI commands and WP-Cron events are blocked from the same changes. Scheduled posts of a protected type stay scheduled and publish normally once the freeze ends. A freeze can start now, run for a set time, or follow a scheduled window in the site's own timezone. Whether it is active is computed from the current time on every relevant request; it never depends on a WP-Cron event firing on time. Pausing comments and forms Under Coverage you can include visitor comments and form submissions in a freeze. People who can bypass the freeze can still submit, WooCommerce orders and checkout are never paused, and the check happens when a submission arrives, never when a page is shown, so page caches cannot serve a stale state. Contact Form 7, WPForms, Ninja Forms, Fluent Forms, Forminator, Formidable and Everest Forms were each checked on a real site, and their visitors see the message in the form. A form set to submit without AJAX shows a plain WordPress notice page instead. Other forms can be added with a filter. The freeze receipt A clean receipt tells your deploy that nothing it can see changed while the freeze was on. Otherwise it lists exactly which posts to look at before anything is overwritten. It covers only the time the freeze was on, so run the check while the freeze is still running. It is a detector, not a synchronizer: it does not merge databases, and the documentation says plainly what it cannot see. Bypass is capability-based, not role-based Roles with manage_options (Administrator, by default) receive the deployment_guard_bypass capability on activation. The check is against the capability, never a role's name, so a custom role can be granted it too. A bypass holder keeps working during a freeze, though their own changes can still be lost if a deployment proceeds concurrently; the freeze protects everyone else's content. WP-CLI is not exempt. wp post update, wp term create, wp media import and equivalent commands from other plugins are blocked the same way; --user=<account with bypass> is the explicit way to act as a specific person. Stillgate's own wp stillgate commands keep working, because they only change Stillgate's own state. Security and privacy Stillgate makes no outbound HTTP requests, sends no data anywhere, needs no account or license key, and collects no telemetry. It adds no database table: six small options, all removed on uninstall. Its activity log never stores request payloads, message bodies or IP addresses, and the receipt keeps counts, timestamps and post IDs only. Known limitations, stated plainly Architecture notes, the enforcement matrix, every hook and the REST API are documented in the GitHub repository.

安装:

  1. Upload the plugin files to /wp-content/plugins/stillgate, or install it through Plugins > Add New > Upload Plugin.
  2. Activate the plugin. Roles with manage_options receive the deployment_guard_bypass capability automatically.
  3. Go to Tools > Stillgate to start a freeze, or use WP-CLI: wp stillgate enable --for=30m.

屏幕截图:

  • A running timed freeze with its end time, buttons to extend it, and the receipt so far.
  • The freeze receipt lists the posts that changed while the freeze was on, and how many comments were paused.
  • What an editor sees: the status in the admin bar and a notice that explains the freeze.

升级注意事项:

0.2.0 Adds timed freezes, a REST API, an optional pause of comments and forms, and a receipt of what changed during a freeze. Nothing changes until you use it: the new coverage options are off, and your stored settings carry over. 0.1.1 Renamed from Deployment Guard. If you installed 0.1.0 from GitHub, install this version, deactivate Deployment Guard, activate Stillgate, and only then delete the old copy; the FAQ has the exact steps. wp deployment-guard is now wp stillgate. 0.1.0 Initial release.

常见问题:

Will this stop the public site from working?

No. Stillgate only restricts editorial writes from logged-in users without the bypass capability. Anonymous visitors, logged-in customers, and every other frontend read or write that is not editorial content stay unaffected. The only exception is one you choose: pausing visitor comments and form submissions for the length of a freeze, which is off by default.

Does this protect against database changes made outside WordPress?

No. Stillgate enforces its freeze through WordPress's own request handling (admin screens, REST, XML-RPC, WP-CLI, WP-Cron), capability checks and content functions. A direct database edit, a raw SQL script, or a separate application writing to the same database is outside anything a WordPress plugin can see or prevent.

Does this sync databases between environments?

No, and it deliberately does not try. Merging two databases that both changed needs knowledge of every plugin's tables and of which side wins each conflict; a plugin that guessed would eventually overwrite the wrong thing. What Stillgate does is make the risky moment safe: it keeps the database still while you copy it, and the receipt tells you afterwards whether anything changed, with the exact post IDs if it did. See the documentation in the repository.

Does this work with my form plugin?

Contact Form 7, WPForms, Ninja Forms, Fluent Forms, Forminator, Formidable and Everest Forms were each checked on a real site. Gravity Forms and Elementor Pro forms are recognized by their known request shapes but were not tested, because they are paid plugins. Any other form can be added with the deployment_guard_form_requests filter, which the repository documents.

Does this work with WooCommerce?

Checkout, orders and order notes keep working during a freeze. Pausing comments also pauses product reviews from visitors. Stock, sales counts and ratings change by themselves while a shop sells, so on a shop the receipt will list products as changed; the deployment_guard_receipt_post_types filter can leave them out.

Does WP-CLI bypass the freeze?

No. Commands that create, update or delete protected posts, pages, media and terms are blocked and exit with an error. Lower-level commands that write post meta, term assignments, widgets, menu locations, theme mods or other options directly are not blocked. Stillgate's own wp stillgate commands keep working because they only change the freeze state itself.

What happens to scheduled (future-dated) posts during a freeze?

A protected post scheduled to publish during an active freeze stays scheduled instead. It publishes normally, through WordPress's own mechanism, once the freeze ends.

Does this work on Multisite?

Yes, per site. Each site's freeze is configured and enforced independently; there is no network-wide screen in this version. A Super Admin is always treated as a bypass holder.

Does this send any data anywhere?

No. Stillgate makes no outbound HTTP requests and has no telemetry. Everything it stores stays in your own site's database.

I installed 0.1.0 as "Deployment Guard". How do I switch to Stillgate?

Stillgate keeps the earlier release's stored settings, so nothing needs to be reconfigured, but both copies share them and only one can run. Install the new ZIP without activating it, deactivate Deployment Guard (this ends a freeze that is active), activate Stillgate, and then delete the old copy while Stillgate is active: Stillgate keeps the freeze configuration, the activity log and every role's bypass capability through that deletion. Do not delete the old copy while Stillgate is inactive, which erases them. If you activate Stillgate first, it stays idle and says so on the Plugins screen until you deactivate the old copy. With WP-CLI: wp plugin install stillgate.zip, wp plugin deactivate deployment-guard, wp plugin activate stillgate, wp plugin delete deployment-guard.

I removed my own bypass capability by mistake. How do I recover?

WP-CLI (wp stillgate disable) and the DEPLOYMENT_GUARD_FORCE constant in wp-config.php both work independently of the deployment_guard_bypass capability.

更新日志:

0.2.0 0.1.1 Renamed from Deployment Guard to Stillgate. The stored settings, activity log and bypass capability carry over. The freeze notice now appears only on the screens where editing is affected and explains how the freeze ends. See the full changelog at https://github.com/digibold/wp-stillgate/blob/main/CHANGELOG.md 0.1.0 Initial release. See the full changelog at https://github.com/digibold/wp-stillgate/blob/main/CHANGELOG.md