Skip to content

Commit c047bd9

Browse files
committed
Configure Azure Developer Pipeline
1 parent 51eeba5 commit c047bd9

File tree

3 files changed

+54
-6
lines changed

3 files changed

+54
-6
lines changed

.github/workflows/azure-dev.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# Run when commits are pushed to main
2+
on:
3+
workflow_dispatch:
4+
push:
5+
# Run when commits are pushed to mainline branch (main or master)
6+
# Set this to the mainline branch you are using
7+
branches:
8+
- main
9+
10+
# Set up permissions for deploying with secretless Azure federated credentials
11+
# https://learn.microsoft.com/en-us/azure/developer/github/connect-from-azure?tabs=azure-portal%2Clinux#set-up-azure-login-with-openid-connect-authentication
12+
permissions:
13+
id-token: write
14+
contents: read
15+
16+
17+
jobs:
18+
build:
19+
runs-on: ubuntu-latest
20+
env:
21+
AZURE_CLIENT_ID: ${{ vars.AZURE_CLIENT_ID }}
22+
AZURE_TENANT_ID: ${{ vars.AZURE_TENANT_ID }}
23+
AZURE_SUBSCRIPTION_ID: ${{ vars.AZURE_SUBSCRIPTION_ID }}
24+
AZURE_ENV_NAME: ${{ vars.AZURE_ENV_NAME }}
25+
AZURE_LOCATION: ${{ vars.AZURE_LOCATION }}
26+
steps:
27+
- name: Checkout
28+
uses: actions/checkout@v4
29+
- name: Install azd
30+
uses: Azure/setup-azd@v2
31+
- name: Setup .NET
32+
uses: actions/setup-dotnet@v4
33+
with:
34+
dotnet-version: |
35+
8.x.x
36+
9.x.x
37+
38+
- name: Log in with Azure (Federated Credentials)
39+
run: |
40+
azd auth login `
41+
--client-id "$Env:AZURE_CLIENT_ID" `
42+
--federated-credential-provider "github" `
43+
--tenant-id "$Env:AZURE_TENANT_ID"
44+
shell: pwsh
45+
46+
47+
- name: Provision Infrastructure
48+
run: azd provision --no-prompt
49+
50+
- name: Deploy Application
51+
run: azd deploy --no-prompt
52+

Web/Pages/Index.cshtml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,9 @@
3737
}
3838

3939
<!-- Hero Section -->
40-
<div class="hero-section bg-primary bg-gradient text-white py-4 mb-4">
40+
<div class="hero-section bg-primary bg-gradient text-white py-4 mb-4 rounded">
4141
<div class="container">
42-
<div class="row align-items-center"> <div class="col-lg-7 col-md-8">
42+
<div class="row align-items-center"><div class="col-lg-7 col-md-8">
4343
<h1 class="display-3 fw-bold mb-3 brand-title">Copilot That Jawn</h1>
4444
<p class="lead fs-4 mb-4">Where Philly innovation meets AI excellence. Master Microsoft Copilot and GitHub Copilot with our expert-curated tips.</p>
4545
<div class="d-flex flex-wrap gap-2"> <a asp-page="/Tips/Index" class="btn btn-light btn-lg">Browse All Tips</a>

Web/Web.csproj

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@
44
<TargetFramework>net9.0</TargetFramework>
55
<Nullable>enable</Nullable>
66
<ImplicitUsings>enable</ImplicitUsings>
7-
<EnableSdkContainerSupport>true</EnableSdkContainerSupport>
8-
<ContainerRepository>copilot-that-jawn</ContainerRepository>
9-
<ContainerBaseImage>mcr.microsoft.com/dotnet/aspnet:9.0</ContainerBaseImage>
10-
<ContainerImageTags>latest</ContainerImageTags>
117
</PropertyGroup>
128

139
<ItemGroup>

0 commit comments

Comments
 (0)