Deployment and DevOps Workflow

Professional Track: Complete this lesson with a working implementation, architecture notes, and a documented trade-off decision.

Overview

Deployment quality is operational quality. A professional Vue delivery pipeline requires deterministic builds, environment governance, and tested rollback procedures.

Environment Strategy

Layered environments

  • Development for rapid feature iteration.
  • Staging for integration and acceptance validation.
  • Production for customer traffic with strict change controls.

Configuration governance

Keep environment variable contracts versioned and documented. Any config addition should include default behavior and failure mode.

Pipeline Design

Build and quality gates

npm ci
npm run lint
npm run type-check
npm run test
npm run build

Artifact integrity

Promote the same built artifact across environments when possible to reduce "works in staging, fails in production" risk.

Release Safety and Recovery

Deployment patterns

  • Blue/green for low-risk cutover and immediate fallback.
  • Canary for progressive rollout and live metric validation.

Rollback playbook

  1. Detect regression through alerts or synthetic checks.
  2. Rollback to previous stable build artifact.
  3. Capture post-incident notes and update deployment checks.

Learning Objectives

  • Set environment strategy for dev, staging, and production.
  • Automate builds and rollbacks in CI/CD.
  • Use CDN caching and cache-busting correctly.

Common Mistakes

  • Deploying directly from local machine output instead of CI artifacts.
  • No rollback test until a real incident happens.
  • Cache headers configured inconsistently between app shell and static assets.

Engineering Notes

Maintain a deployment runbook with owner, pre-checks, release checks, rollback command path, and communication plan.

Practice Scope

Deliver one production-style mini-feature, include implementation notes, and record one performance, reliability, or maintainability trade-off in your commit summary.

Back to roadmap: Vue Roadmap