Chapter 20: Deployment and portfolio presentation
1. Why deployment matters
A project that only runs on your laptop is still invisible. In this chapter, you turn the Music Time Machine into a deployed app someone can open from a link.
You've already built the hard parts: OAuth, SQLite, the per-feature scripts, the Flask app, the dashboard, and the test suite. Now you'll deploy the app to Railway with a real domain, a persistent volume so the SQLite database survives the next deploy, and an HTTPS redirect URI Spotify will accept.
You'll then write the README, screenshots, and STAR-method answers a recruiter actually reads on the way to the live URL. By the end, the Music Time Machine becomes a portfolio piece a hiring manager can experience in fifteen seconds, not the fifteen-minute clone-and-configure that most candidates ship.
The portfolio benefit
You're in a technical interview. The recruiter asks about your projects. You describe the Music Time Machine: OAuth authentication, SQLite database, algorithmic playlists, Flask dashboard. They're interested. They ask to see it.
Option A: "It's on my laptop. You'd need to clone the repo, install dependencies, set up Spotify credentials, and run the server locally."
Option B: "Here's the live URL: music-time-machine-production.up.railway.app. I'll authenticate right now and show you the playlist generator working."
Option A requires trust. Option B provides proof. A deployed application transforms your portfolio from code you wrote to a product you shipped.
This chapter turns the Music Time Machine from a local Flask project into a deployed portfolio app.
-
Prepare the app for production: move secrets out of
.env, validate required settings, add a Gunicorn start command, and make the app safe to run outside your laptop. -
Deploy it to Railway: connect the GitHub repo, add environment variables, create a persistent
/datavolume for SQLite, and generate a public HTTPS URL. -
Make OAuth work live: update Spotify with the production redirect URI and connect that value to Railway through
SPOTIFY_REDIRECT_URI. - Debug the first deploy: use Railway logs to diagnose missing variables, bad start commands, database path problems, OAuth errors, and broken dependencies.
- Present the project well: write a recruiter-friendly README with a live URL, screenshots, technical highlights, and STAR-method interview answers.