Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@
"tflint": "none",
"terragrunt": "none"
},
"ghcr.io/va-h/devcontainers-features/uv:1": {},
"ghcr.io/microsoft/aspire-devcontainer-feature/aspire:2": {}
"ghcr.io/va-h/devcontainers-features/uv:1": {}
},
"customizations": {
"vscode": {
Expand All @@ -46,8 +45,7 @@
"dbaeumer.vscode-eslint",
"bradlc.vscode-tailwindcss",
"GitHub.copilot",
"ms-azuretools.vscode-azure-mcp-server",
"microsoft-aspire.aspire-vscode"
"ms-azuretools.vscode-azure-mcp-server"
]
}
},
Expand Down
8 changes: 8 additions & 0 deletions .devcontainer/on-create.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@ else
playwright install --with-deps chrome
fi

# Install Aspire CLI for the MCP server (aspire agent mcp).
# Installed via the standalone script so we don't need .NET SDK or the VS Code
# extension (which pulls in C# DevKit and .NET Installer as dependencies).
if ! command -v aspire &> /dev/null; then
echo "🌐 Installing Aspire CLI..."
curl -sSL https://aspire.dev/install.sh | bash
fi

# Install Azure Functions Core Tools for local Durable Functions development.
if ! command -v func &> /dev/null; then
echo "⚡ Installing Azure Functions Core Tools..."
Expand Down
10 changes: 9 additions & 1 deletion .devcontainer/post-create.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,17 @@ if [ -f api/.env ] && ! grep -q "^DEBUG=true" api/.env; then
printf '\nDEBUG=true\n' >> api/.env
fi

# Run database migrations
# Disable HTTPS redirect for local OAuth (no TLS termination locally)
if [ -f api/.env ] && ! grep -q "^WEB_SECURITY__REQUIRE_HTTPS=" api/.env; then
echo "📝 Adding WEB_SECURITY__REQUIRE_HTTPS=false to api/.env..."
printf '\nWEB_SECURITY__REQUIRE_HTTPS=false\n' >> api/.env
fi

# Run database migrations and sync curriculum content
echo "🗄️ Running database migrations..."
(cd api && uv run alembic upgrade head)
echo "📚 Syncing curriculum content into database..."
(cd api && uv run python -m learn_to_cloud_shared.cli.sync_curriculum)

echo "✅ Setup complete!"
echo ""
Expand Down
4 changes: 4 additions & 0 deletions api/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ DATABASE__URL=postgresql+asyncpg://postgres:postgres@db:5432/learn_to_cloud
# in deployed environments (Container Apps sets this).
ENVIRONMENT=development

# Disable HTTPS redirect for OAuth callback (localhost has no TLS).
# Production defaults to true since Azure Container Apps terminates TLS.
WEB_SECURITY__REQUIRE_HTTPS=false

# GitHub OAuth. Create an OAuth App at https://github.com/settings/developers
# OAUTH__CLIENT_ID=your_github_client_id
# OAUTH__CLIENT_SECRET=your_github_client_secret
Expand Down