If you’ve built a full stack app and want a super easy way to get it online, Render + Docker is a winning combo. In this quick guide, I’ll show you how I deployed my app using a Dockerfile on Render.com — with zero server config!
Prerequisites
- A working app (Node.js, Python, etc.)
- A
Dockerfile
in your project root - A GitHub repository
- A free account on Render
Step 1: Create a Dockerfile
Here’s an example Dockerfile
for a Node.js app:
# Use official Node image
FROM node:18
# Set working directory
WORKDIR /app
# Copy all files
COPY . .
# Install dependencies
RUN npm install
# Start the app
CMD ["npm", "start"]
# Expose port
EXPOSE 3000
For Python Flask, you might use:
FROM python:3.11
WORKDIR /app
COPY . .
RUN pip install -r requirements.txt
CMD ["python", "app.py"]
EXPOSE 5000
Make sure to customize the Dockerfile for your tech stack.
Step 2: Push Your Code to GitHub
If you haven’t already:
git init
git add .
git commit -m "initial commit"
git remote add origin <your-repo-url>
git push -u origin main
Step 3: Create a Web Service on Render
- Go to https://render.com
- Click New + → Web Service
- Connect your GitHub repo
- Render will auto-detect your Dockerfile
- Set the following:
- Name: Anything you like
- Environment: Docker
- Build Command: Leave empty
- Start Command: Use from Dockerfile
-
Port:
3000
(or5000
for Flask)
- Click Create Web Service
Render will start building your image and deploy it automatically.
Pro Tips
- Use
.env
file locally and set the same Environment Variables in Render - Add a
render.yaml
file for Infrastructure as Code (optional) - Set up automatic deploys on every GitHub push
- Monitor logs directly in the Render dashboard
Conclusion
Docker + Render makes it dead simple to go from local development to live deployment. No AWS console, no NGINX config — just push and deploy.
If you found this helpful, leave a like, share with your dev friends, or drop questions in the comments!
Top comments (0)