Skip to content
ML SystemPart 4: InfrastructureChapter 11
CH.11 ~25 min

Infrastructure

Bundling, PaaS, and CORS policies.

DeploymentPaaSCORS
  • Build and bundle a React application for production.
  • Configure an Express server to serve static frontend assets.
  • Deploy a full-stack application to a cloud provider like Render.

01 Deployment & Infrastructure Viz

Definition

Build Process

The process of compiling, minifying, and bundling frontend assets into static files (HTML, CSS, JS) ready for production.

Proxy & CORS

During development, we use proxy settings in Vite to bypass Same-Origin Policy restrictions, allowing the frontend to communicate with a local backend on a different port.

02 Production Integration

Deeper InsightCloud providers assign ports dynamically via environment variables (process.env.PORT); backends must be flexible enough to listen on these assigned ports. Click to collapse

Key Takeaways

  1. 1Deployment involves bundling the frontend and serving it via the backend.
  2. 2Same-Origin Policy is a critical browser security feature handled via CORS or proxies.
  3. 3Environment variables are essential for configuring apps across different environments.

CH.11

Chapter Complete

Up next:Testing & Auth

Chapter Progress

Reading
Exercise

Interact with the visualization

Quiz

Chapter Quiz

No quiz available for this chapter.