From e4527d01727f000a8f4563120ab35ccdc80e30b0 Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Thu, 28 Sep 2023 23:27:35 +0100 Subject: [PATCH] daily-email: add 2023-09-25 Should you use a staging environment? --- src/content/daily-email/2023-09-25.md | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 src/content/daily-email/2023-09-25.md diff --git a/src/content/daily-email/2023-09-25.md b/src/content/daily-email/2023-09-25.md new file mode 100644 index 00000000..d44d8b1b --- /dev/null +++ b/src/content/daily-email/2023-09-25.md @@ -0,0 +1,27 @@ +--- +title: > + Should you use a staging environment? +pubDate: 2023-09-25 +permalink: > + archive/2023/09/25/should-you-use-a-staging-environment +tags: + - software-development +--- + +The purpose of any pre-production version of your website or application (any version that isn't the public live one) is to mimic the production version and as a test run for deployments. + +**If I deploy this feature, will it break the website?** + +The issue with most staging and other pre-production environments is that they differ from what's on production. It may have been some time since the latest data was added, and its value is only as good as how close to production it is and how likely it is to find potential issues in production. + +If they differ greatly, the staging environment offers no value. + +It's not a true comparison, and instead of being a test run for a deployment to production, you're only reviewing the deployment to the staging environment itself. + +## Here's the thing + +The best situation I've experienced is where a sanitised snapshot was synced to all pre-production environments every night. + +I knew that my environment was, at most, a single day out of date, and I was confident that my changes would work in production if they did there. + +In that situation, the staging site works and testing it has value, but if it's weeks or months out of date, it doesn't, as there are too many differences for it to be an accurate representation.