Contact
Managed Hosting

Managed Deployments vs Basic Hosting: Pipelines and Rollback

This page explains how a managed deployment pipeline differs from basic web hosting, covering build artefacts, staging environments, database migrations, atomic releases and rollback, and is written for IT managers, digital leads and agency owners who are deciding who should own the release process for a business-critical website.

How most websites are still deployed

A surprising number of commercially important Australian websites are still updated the same way they were in 2010. Someone opens an SFTP client, drags a folder of changed files onto the production server, refreshes the page and hopes. If a database change is needed, they run a query in phpMyAdmin. If something looks wrong, they drag the old files back and try to remember which ones they touched.

This works until it does not. The failure modes are predictable and all of them are expensive:

  • A partial upload leaves the site in a half-deployed state for the ninety seconds the transfer takes, which on a busy ecommerce site is hundreds of broken page views.
  • Dependencies on the server no longer match the ones the developer tested against, so a template renders on a laptop and throws a fatal error in production.
  • A schema change is applied but the matching code is not, or the other way round, and the site loses write functionality until someone works out which half is missing.
  • Nobody can say with certainty what the previous state was, so rolling back becomes an archaeology exercise rather than a command.
  • Hotfixes made directly on production are never committed, so the next proper release silently overwrites them.

Basic hosting does nothing to prevent any of this, because basic hosting sells you a filesystem and a database and stops there. The gap between what a host is responsible for and what a website actually needs is the same gap we describe in web hosting versus managed hosting, and the release process is where it bites hardest.

What a deployment pipeline actually does

A pipeline replaces "copy files up" with a repeatable, auditable sequence that produces an identical result every time it runs. For a typical PHP CMS on Linux, the steps look like this:

  1. Trigger. A merge into a protected branch, or a manual approval against a tagged release, starts the run. The commit SHA becomes the identity of the release.
  2. Checkout and build. The runner clones the repository at that SHA and installs dependencies deterministically: composer install --no-dev --optimize-autoloader against a committed lock file, npm ci rather than npm install, then the asset build.
  3. Automated checks. Static analysis, linting, unit tests and any smoke tests run against the build before it is allowed near a server.
  4. Artefact. The result is packaged as a single immutable artefact: code plus vendor directory plus compiled CSS and JavaScript, with no build toolchain inside it.
  5. Deploy to staging. The artefact is released to a staging environment that matches production, and migrations run there first.
  6. Deploy to production. The same artefact, not a rebuild, is shipped to production, migrations are applied, caches are warmed and the release is switched in.
  7. Verify. Health checks, a synthetic transaction against a key journey, and error rate monitoring for a defined window after the switch.

The important property is that the artefact deployed to production is bit-for-bit the artefact that passed staging. If you rebuild on each environment, you have tested a different thing from the one you shipped.

Environments, and keeping them honest

Three environments is the practical minimum: local, staging and production. The value of staging collapses the moment it stops resembling production, and it drifts constantly unless someone owns it.

What has to match

  • PHP or Node major and minor version, and the extension set.
  • Database engine and version, including MySQL versus MariaDB, because collation and strict mode behaviour differ.
  • Web server, PHP-FPM pool settings and opcache configuration.
  • Search, queue and cache services: Elasticsearch, Redis, cron schedules.
  • A recent, sanitised copy of production data, with personal information scrubbed where privacy obligations require it.

What should deliberately differ

  • Secrets and API keys, which belong in environment variables, not in the repository.
  • Outbound email, which should be trapped rather than delivered.
  • Payment gateways, pointed at sandbox credentials.
  • Search engine indexing, blocked by authentication rather than by robots.txt alone.

Why you do not build on production

Running a dependency install on a live web server pulls packages over the network at the worst possible moment, consumes CPU that paying visitors need, and makes the deployment outcome dependent on whether a registry is reachable. It also means the production box needs Composer, Node and a build toolchain installed, which is extra attack surface on a machine that should run as little as possible.

Database migrations, the hardest part of any release

Code can be replaced atomically. Databases cannot, because they hold state. This is where most real outages originate.

Every platform has its own mechanism: Silverstripe has dev/build, Drupal has drush updatedb and configuration import, Laravel has php artisan migrate, WordPress has plugin and core upgrade routines that mutate tables on first load. In all cases the discipline is the same. Migrations must be committed alongside the code that depends on them, must be idempotent, and must be run in a known order rather than triggered by whoever happens to load the admin area first.

For anything that cannot be reversed cleanly, the expand and contract pattern is the safe route. Add the new column and write to both old and new in one release. Backfill in a second step. Only once the old column is provably unused do you drop it, in a later release. Three small releases carry far less risk than one clever one, and each of them can be rolled back on its own.

Large tables need extra care. An ALTER TABLE on a multi-million-row InnoDB table can lock writes for minutes. Online schema change tooling, or a maintenance window agreed in advance, is the difference between a planned event and an incident. This is the same class of planning that goes into a zero-downtime host migration, where state and traffic have to move without the user noticing.

Atomic releases and zero downtime

The standard approach on a single server is a releases directory with a symlink. Each deployment unpacks into /var/www/releases/20240612T094500, shared paths such as uploaded assets and the environment file are symlinked in from /var/www/shared, and only when the release is fully prepared is /var/www/current repointed. The symlink switch is a single filesystem operation. Visitors mid-request finish against the old release; the next request hits the new one.

Two details catch people out. PHP's realpath cache and opcache both hold references to the old path, so a graceful PHP-FPM reload has to follow the switch. And anything writable that lives inside the application directory, typically user uploads and generated files, must be moved into shared storage first, or it disappears with the previous release.

On multi-server or containerised setups the same principle is expressed as a rolling or blue/green deployment behind a load balancer, with health checks deciding when each node rejoins the pool. Keeping the previous five releases on disk costs very little and makes the rollback path trivial.

Rollback: what can and cannot be reversed

"We can just roll back" is only true for part of the system. Being specific about which part is what separates a plan from a hope.

Change type Reversible? Mechanism
Application code Yes, in seconds Repoint symlink to previous release, reload PHP-FPM
Compiled assets Yes Shipped inside the artefact, so they revert with the code
Additive schema change Yes, usually New column or table is simply ignored by the old code
Destructive schema change No Requires restore from backup and replay of transactions
Data transformation Rarely Needs a written reverse migration or a point-in-time restore
Content entered after release No Lost by any database restore to a pre-release point
Third-party integration state No Webhooks already sent and payments already taken cannot be recalled

The practical consequence is that the rollback decision has a clock on it. Reverting code ten minutes after a release is free. Reverting a database two hours after a release costs every order, enquiry and content edit made in between. Managed deployment means someone is watching error rates immediately after the switch so the decision gets made inside the cheap window, which is one reason release verification belongs alongside monitoring that goes beyond uptime.

Comparing the three models

Capability Basic hosting Hosting with staging Fully managed deployments
Release method SFTP or control panel file manager Manual push, then copy staging to live Git-triggered pipeline from a tagged commit
Build location On production, if at all Often on production Isolated runner, immutable artefact
Automated tests before release None Optional, usually manual Required gate, release blocked on failure
Database migrations Run by hand Run by hand on each environment Versioned, run in sequence, rehearsed on staging
Downtime during release Seconds to minutes Seconds None, atomic switch
Rollback time Unbounded Minutes, manual Seconds for code, documented plan for data
Record of what changed File timestamps Partial Commit, approver, time, artefact and outcome
Who is accountable when it breaks Nobody agrees Split between host and developer A single provider under an SLA

Release records and the audit trail

Once a website falls inside a government, financial services or health obligation, "we updated the site last Tuesday" is not an acceptable answer. An auditor asks what changed, who approved it, when it went live, how it was tested and what the rollback plan was. A pipeline answers all five by construction, because every release is tied to a commit range, an approver, a timestamp and a build log.

The same record is what makes incident analysis quick. When error rates climb at 2:14pm, the first question is always what changed, and a dated release log turns that from a conversation into a lookup. It is also the backbone of website governance and risk management, where change control, access control and evidence all have to line up.

Content and configuration drift

Even a disciplined pipeline has a seam: content and configuration are edited in production, while code moves from development to production. Pushing a database the wrong way destroys real content, so the rule is that code and configuration move forward and content never moves backward.

Keeping configuration out of the database is what makes this workable. Drupal's configuration synchronisation, Silverstripe's YAML config, environment variables for anything secret, and infrastructure defined in version control all mean the deployable state of the site lives in the repository. What remains in the database is genuinely content, which can be copied down to staging and never up. Where a CMS insists on storing settings in the database, those settings need to be documented as a post-release checklist item rather than quietly re-entered by whoever notices.

Frequently Asked Questions

How do managed deployment services compare with basic web hosting?

Basic web hosting provides the server, storage and database, and leaves every aspect of getting code onto it to you. A managed deployment service owns the pipeline: building the release in isolation, testing it, applying database migrations in a known order, switching it in atomically and rolling it back if verification fails. The infrastructure may look similar on paper; the difference is who is accountable for the release and for the recovery.

Do I need a staging environment for a small website?

If the website generates revenue or leads, yes. Staging is not about size, it is about whether you can afford to discover a fatal error in front of customers rather than in front of a developer. A staging environment that matches production in PHP version, database engine and service configuration catches the majority of release failures before they reach anyone who matters.

Can every deployment be rolled back?

Code can almost always be rolled back in seconds by repointing to the previous release. Database changes often cannot, because dropping a column or transforming data destroys information that a code revert does not restore. The workable approach is to make schema changes additive and backwards compatible, deploy them separately from the code that uses them, and keep a tested point-in-time restore for the cases where that is not possible.

What is an atomic deployment?

An atomic deployment prepares the entire new release on the server first, then switches to it in a single operation, usually by repointing a symlink or moving traffic to a new set of containers. Visitors never see a partially updated site, because at any instant they are served either the complete old release or the complete new one. It also makes rollback a matter of switching back rather than re-uploading files.

Does managed hosting in Australia include the deployment pipeline?

Not automatically. Many providers that describe themselves as managed cover the operating system, patching and backups but treat anything inside the application directory as the client's responsibility. Ask explicitly whether the provider builds and deploys your code, runs your database migrations and owns the rollback decision, because that boundary is where most finger-pointing between host and developer originates.

Who should own the pipeline if we already have an internal development team?

Internal teams usually write the application well and maintain the release infrastructure sporadically, because pipeline work only becomes urgent when it breaks. A common split is for the internal team to own the code and for an external provider to own the environments, pipeline, migrations rehearsal and production release under an SLA. That keeps release discipline from depending on whoever happens to have time that week.

Where UnDigital fits

UnDigital runs deployment pipelines for WordPress, Silverstripe, Drupal, Laravel and headless front ends on Next.js and Nuxt, across our own Australian infrastructure and on client-owned AWS and Azure accounts. Every engagement begins with an infrastructure audit that documents how releases currently happen, where the manual steps are and what would be required to roll back today.

Two of our managed hosting models apply here. Hosting plus Management means we own the servers and the release process end to end. Management Only means you keep your existing cloud account and we take over the environments, pipeline, migrations and release verification. In both cases the scope is written down rather than assumed, in the same way we set out in what website managed services actually include.

If your current arrangement involves dragging files onto a production server and hoping, an audit will tell you exactly what that is costing you in risk, and what a tested release and rollback path would look like for your stack.

Get your release process audited

Reviews from our client partners.

"Thanks so much for your comprehensive strategy and execution of our digital ecosystem.

I can finally sleep at night knowing that everything is under control, secure and scalable.

Thank you!!!".

Corporate Marketing Manager, Sekisui House

"Thanks for all your help. This project was in such good hands from the beginning. We really appreciate all your hard work and expertise!!"

Retail Marketing Manager, West Village

Hand your deployment pipeline to specialists

@undigital