Azure Static Website - Quick Start Guide¶
This guide will help you deploy the Nutri-E website to Azure Storage in under 5 minutes.
Prerequisites¶
- Azure account (free trial available)
- Azure CLI installed (download here)
- GitHub repository admin access
Quick Setup (5 minutes)¶
Step 1: Login to Azure (30 seconds)¶
Your browser will open for authentication.
Step 2: Run Setup Script (2 minutes)¶
The script will: - ✅ Create Azure resources - ✅ Upload your website - ✅ Generate GitHub credentials - ✅ Display your live website URL
Step 3: Configure GitHub Secrets (2 minutes)¶
The script outputs the secrets you need. Copy them to GitHub:
- Go to:
https://github.com/Stig-Johnny/nutri-e/settings/secrets/actions - Click "New repository secret"
- Add these three secrets:
Secret 1: AZURE_CREDENTIALS
Secret 2: AZURE_STORAGE_ACCOUNT
Secret 3: AZURE_RESOURCE_GROUP
Step 4: Test Deployment (30 seconds)¶
# Make a test change
echo "<!-- Updated $(date) -->" >> website/index.html
# Commit and push
git add .
git commit -m "feat: add Azure deployment"
git push origin main
Go to GitHub Actions tab to watch the deployment!
Your Website is Live! 🎉¶
After setup, your website will be at:
Example: https://nutriewebsite.z16.web.core.windows.net
What Happens Next?¶
Every time you push changes to website/ folder on the main branch:
1. GitHub Action automatically triggers
2. Files are uploaded to Azure Storage
3. Your website updates in ~30 seconds
Customization¶
Change Storage Account Name¶
Change Azure Region¶
Deploy to Different Region¶
Available regions:
- westeurope - West Europe (Amsterdam)
- northeurope - North Europe (Dublin)
- eastus - East US (Virginia)
- westus - West US (California)
- southeastasia - Southeast Asia (Singapore)
Troubleshooting¶
"Storage account name not available"¶
Storage account names must be globally unique. Try:
"Subscription not found"¶
Make sure you're logged in:
GitHub Action fails¶
- Check secrets are set correctly (exact JSON format)
- Verify secret names match exactly (case-sensitive)
- Re-run the workflow
Cost¶
Expected monthly cost: $0.50 - $2.00 for a typical small website
Includes: - Storage (~$0.02/GB) - Bandwidth (first 5GB free) - Transactions (~$0.005/10K requests)
Next Steps¶
- [ ] Add custom domain: See AZURE_DEPLOYMENT.md
- [ ] Enable CDN: See AZURE_DEPLOYMENT.md
- [ ] Monitor traffic: Use Azure Portal → Storage Account → Monitoring
Full Documentation¶
See AZURE_DEPLOYMENT.md for complete documentation including: - Custom domain setup - CDN configuration - Monitoring and logs - Security best practices - Alternative deployment options
Support¶
- Azure Issues: Check AZURE_DEPLOYMENT.md
- GitHub Action Issues: Check workflow logs in Actions tab
- Questions: Open an issue in the repository