Forum Discussion
Unable to get Python3.12 running on Azure App services
Simple Steps to Deploy Django on Azure App Service with Python 3.12
1. Create Web App in Azure
Go to Azure Portal > App Services
Click Create Web App
Select Python 3.12 (or latest)
2. Setup Django Project on Your PC
# Create project django-admin startproject myproject cd myproject # Create virtual environment python -m venv venv source venv/bin/activate # (Windows: venv \Scripts \ activate) # Install required packages pip install django gunicorn openai # Add other dependencies # Freeze dependencies pip freeze > requirements.txt
3. Configure requirements.txt
Ensure it includes:
django gunicorn openai
4. Deploy to Azure
Use Git or ZIP Deploy: Push code to Azure using GitHub, Azure CLI, or ZIP
Configure Startup Command in Azure: gunicorn --workers=4 myproject.wsgi
Check Logs in Azure > App Service > Log Stream
5. Apply Migrations & Run
SSH into Azure Web App and run:
python manage.py migrate python manage.py createsuperuser
Your Django app is now live on Azure! 🚀