Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A mini-hack series of challenges based on this #13

Open
wants to merge 83 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
83 commits
Select commit Hold shift + click to select a range
4566f7c
Update SampleApp.jmx
jometzg Dec 9, 2021
6b47642
Update workflow.yml
jometzg Dec 9, 2021
7d20ef3
Update workflow.yml
jometzg Dec 9, 2021
0d7f362
Update deploymentscript.ps1
jometzg Dec 9, 2021
785f10b
Update deploymentscript.ps1
jometzg Dec 9, 2021
d260dd7
Update SampleApp.yaml
jometzg Dec 9, 2021
41faea2
Update workflow.yml
jometzg Dec 9, 2021
7044ed0
Update SampleApp.yaml
jometzg Dec 9, 2021
a39aeaf
Set up CI with Azure Pipelines
jometzg Jan 6, 2022
9108227
Update load-test-pipeline.yml for Azure Pipelines
jometzg Jan 6, 2022
249e3f9
Update load-test-pipeline.yml for Azure Pipelines
jometzg Jan 6, 2022
2d4096d
Set up CI with Azure Pipelines
jometzg Jan 6, 2022
59581f3
Update load-alone-pipelines.yml for Azure Pipelines
jometzg Jan 6, 2022
367c7a3
Update load-alone-pipelines.yml for Azure Pipelines
jometzg Jan 6, 2022
30b86bd
Update windows-webapp-template.json
jometzg May 20, 2022
6a8bfed
Update workflow.yml
jometzg May 20, 2022
73d5daf
Update workflow.yml
jometzg May 20, 2022
2b5b1d9
Update workflow.yml
jometzg May 20, 2022
0ac7a18
Update SampleApp.jmx
jometzg May 20, 2022
c8c2aaf
Create SampleAppParam.jmx
jometzg May 20, 2022
3557d5a
Update SampleApp.yaml
jometzg May 20, 2022
a8c4268
Update workflow.yml
jometzg May 20, 2022
0c31dcf
Update workflow.yml
jometzg May 20, 2022
8b1a94e
Update workflow.yml
jometzg May 20, 2022
b3bdb95
Update workflow.yml
jometzg May 20, 2022
eed87bb
Update README.md
jometzg May 20, 2022
dacddb3
Update README.md
jometzg May 20, 2022
82bd044
Update README.md
jometzg May 20, 2022
4352f3d
Create workshop.md
jometzg May 23, 2022
63edb96
Update workshop.md
jometzg May 23, 2022
e4d6a7c
Update workshop.md
jometzg May 23, 2022
6bb96e2
Update workshop.md
jometzg May 23, 2022
cf3280f
Update workshop.md
jometzg May 23, 2022
91ec226
Update workshop.md
jometzg May 24, 2022
6116b0a
Update workshop.md
jometzg May 24, 2022
c73de7e
Update workshop.md
jometzg May 24, 2022
fa4074b
Add files via upload
jometzg May 24, 2022
c76b54e
Add files via upload
jometzg May 24, 2022
5684279
Update workshop.md
jometzg May 24, 2022
55d1441
Add files via upload
jometzg May 24, 2022
d9823b3
Update workshop.md
jometzg May 24, 2022
0f0533a
Add files via upload
jometzg May 24, 2022
54d1266
Add files via upload
jometzg May 24, 2022
dc06c7a
Update workshop.md
jometzg May 24, 2022
72463a4
Add files via upload
jometzg May 24, 2022
7d881fa
Update workshop.md
jometzg May 24, 2022
a2b8c2e
Update workflow.yml
jometzg May 24, 2022
9023df0
Update workshop.md
jometzg May 24, 2022
00536ab
Add files via upload
jometzg May 24, 2022
f751f23
Add files via upload
jometzg May 24, 2022
aa571e2
Update workshop.md
jometzg May 24, 2022
b6f918c
Create README-OLD.md
jometzg May 24, 2022
9b68801
Update README.md
jometzg May 24, 2022
50af575
Update README.md
jometzg May 24, 2022
84f3ed6
Update README.md
jometzg May 24, 2022
bba2e24
Update workflow.yml
jometzg May 24, 2022
1435e6d
Update README.md
jometzg May 25, 2022
4261705
Update README.md
jometzg May 25, 2022
4dc1b39
Update README.md
jometzg May 25, 2022
95f85e1
Update deploymentscript.ps1
jometzg May 25, 2022
08492b6
Update README.md
jometzg May 25, 2022
7a6a4ad
Update README.md
jometzg May 26, 2022
6ff91d5
Update workflow.yml
jometzg Aug 15, 2022
f5fee63
Update workflow.yml
jometzg Nov 8, 2022
51eee68
Add or update the Azure App Service build and deployment workflow config
jometzg Apr 28, 2023
99c4466
Remove the Azure App Service build and deployment workflow config
jometzg Apr 28, 2023
56b8365
added credentials policy
jometzg May 22, 2023
0458b62
Update windows-webapp-template.json
jometzg May 22, 2023
e5d19ae
Add or update the Azure App Service build and deployment workflow config
jometzg May 24, 2023
51c317c
Setup OIDC
jometzg May 24, 2023
958a85b
Add or update the Azure App Service build and deployment workflow config
jometzg Mar 28, 2024
d749039
Add or update the Azure App Service build and deployment workflow config
jometzg Jun 10, 2024
0b7cb9c
Create Container-readme.md
jometzg Jul 9, 2024
f170745
Update Container-readme.md
jometzg Jul 9, 2024
cafcde6
Add files via upload
jometzg Jul 9, 2024
66e5c50
Update Container-readme.md
jometzg Jul 9, 2024
7dd6ce9
Update Container-readme.md
jometzg Jul 9, 2024
1110cdc
Add files via upload
jometzg Jul 9, 2024
db34353
Add files via upload
jometzg Jul 9, 2024
e246363
Create Dockerfile
jometzg Jul 10, 2024
a068afe
Create aks-manifest.yml
jometzg Jul 10, 2024
d4d2615
Update README.md
jometzg Jul 10, 2024
364b352
Update Container-readme.md
jometzg Jul 10, 2024
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
65 changes: 65 additions & 0 deletions .github/workflows/main_app-7tmd2uumpfvoi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# Docs for the Azure Web Apps Deploy action: https://github.com/Azure/webapps-deploy
# More GitHub Actions for Azure: https://github.com/Azure/actions

name: Build and deploy Node.js app to Azure Web App - app-7tmd2uumpfvoi

on:
push:
branches:
- main
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Set up Node.js version
uses: actions/setup-node@v1
with:
node-version: '18.x'

- name: npm install, build, and test
run: |
npm install
npm run build --if-present
npm run test --if-present

- name: Upload artifact for deployment job
uses: actions/upload-artifact@v2
with:
name: node-app
path: .

deploy:
runs-on: ubuntu-latest
needs: build
environment:
name: 'production'
url: ${{ steps.deploy-to-webapp.outputs.webapp-url }}
permissions:
id-token: write #This is required for requesting the JWT

steps:
- name: Download artifact from build job
uses: actions/download-artifact@v2
with:
name: node-app

- name: Login to Azure
uses: azure/login@v1
with:
client-id: ${{ secrets.AZURE_CLIENT_ID92B4 }}
tenant-id: ${{ secrets.AZURE_TENANT_ID92B4 }}
subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID92B4 }}

- name: 'Deploy to Azure Web App'
id: deploy-to-webapp
uses: azure/webapps-deploy@v2
with:
app-name: 'app-7tmd2uumpfvoi'
slot-name: 'production'
package: .

56 changes: 56 additions & 0 deletions .github/workflows/main_jjnodeapp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Docs for the Azure Web Apps Deploy action: https://github.com/Azure/webapps-deploy
# More GitHub Actions for Azure: https://github.com/Azure/actions

name: Build and deploy Node.js app to Azure Web App - jjnodeapp

on:
push:
branches:
- main
workflow_dispatch:

jobs:
build:
runs-on: windows-latest

steps:
- uses: actions/checkout@v4

- name: Set up Node.js version
uses: actions/setup-node@v3
with:
node-version: '14.16.0'

- name: npm install, build, and test
run: |
npm install
npm run build --if-present
npm run test --if-present

- name: Upload artifact for deployment job
uses: actions/upload-artifact@v3
with:
name: node-app
path: .

deploy:
runs-on: ubuntu-latest
needs: build
environment:
name: 'Production'
url: ${{ steps.deploy-to-webapp.outputs.webapp-url }}

steps:
- name: Download artifact from build job
uses: actions/download-artifact@v3
with:
name: node-app

- name: 'Deploy to Azure Web App'
uses: azure/webapps-deploy@v2
id: deploy-to-webapp
with:
app-name: 'jjnodeapp'
slot-name: 'Production'
package: .
publish-profile: ${{ secrets.AZUREAPPSERVICE_PUBLISHPROFILE_B92DE938C7D24A50B04CF415EAD14B00 }}
56 changes: 56 additions & 0 deletions .github/workflows/main_jjtestnodebp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Docs for the Azure Web Apps Deploy action: https://github.com/Azure/webapps-deploy
# More GitHub Actions for Azure: https://github.com/Azure/actions

name: Build and deploy Node.js app to Azure Web App - jjtestnodebp

on:
push:
branches:
- main
workflow_dispatch:

jobs:
build:
runs-on: windows-latest

steps:
- uses: actions/checkout@v4

- name: Set up Node.js version
uses: actions/setup-node@v3
with:
node-version: '14.16.0'

- name: npm install, build, and test
run: |
npm install
npm run build --if-present
npm run test --if-present

- name: Upload artifact for deployment job
uses: actions/upload-artifact@v3
with:
name: node-app
path: .

deploy:
runs-on: ubuntu-latest
needs: build
environment:
name: 'Production'
url: ${{ steps.deploy-to-webapp.outputs.webapp-url }}

steps:
- name: Download artifact from build job
uses: actions/download-artifact@v3
with:
name: node-app

- name: 'Deploy to Azure Web App'
uses: azure/webapps-deploy@v2
id: deploy-to-webapp
with:
app-name: 'jjtestnodebp'
slot-name: 'Production'
package: .
publish-profile: ${{ secrets.AZUREAPPSERVICE_PUBLISHPROFILE_AE1ACAC9766D4799A10ABB678419525B }}
60 changes: 12 additions & 48 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This is a basic workflow to help you get started with Actions

name: Sample App deploy
name: Sample App load test

# Controls when the workflow will run
on:
Expand All @@ -9,58 +9,15 @@ on:
- main

env:
AZURE_WEBAPP_NAME: "<Name of your webapp>" # set this to your application's name
LOAD_TEST_RESOURCE: "<Name of your load test resource>"
LOAD_TEST_RESOURCE_GROUP: "<Name of your load test resource group>"
AZURE_WEBAPP_PACKAGE_PATH: '.' # set this to the path to your web app project, defaults to the repository root
NODE_VERSION: '14.15.1' # set this to the node version to use
LOCATION: "West US"
APPINSIGHTLOCATION: "West US"
DATABASEACCOUNTLOCATION: "westus"
LOAD_TEST_RESOURCE: "eastloadtest"
LOAD_TEST_RESOURCE_GROUP: "loadtest-rg"
ENDPOINT_URL: "jjttarg.azurewebsites.net"

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
build-and-deploy:
# The type of runner that the job will run on
runs-on: ubuntu-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: Checkout GitHub Actions
uses: actions/checkout@v2

- name: Login to Azure
uses: azure/login@v1
continue-on-error: false
with:
creds: ${{ secrets.AZURE_CREDENTIALS }}

# Deploy Arm template
- name: Deploy ARM Template
uses: azure/powershell@v1
continue-on-error: false
with:
inlineScript: |
az group create --name "${{ env.AZURE_WEBAPP_NAME }}-rg" --location "${{ env.LOCATION }}"
$deploymentOutputs = az deployment group create --resource-group "${{ env.AZURE_WEBAPP_NAME }}-rg" --mode Incremental --template-file ./windows-webapp-template.json --parameters webAppName="${{ env.AZURE_WEBAPP_NAME }}" --parameters hostingPlanName="${{ env.AZURE_WEBAPP_NAME }}-host" --parameters appInsightsLocation="${{ env.APPINSIGHTLOCATION }}" --parameters databaseAccountId="${{ env.AZURE_WEBAPP_NAME }}db" --parameters databaseAccountLocation="${{ env.DATABASEACCOUNTLOCATION }}" -o json
$deploymentOutputs = $deploymentOutputs | ConvertFrom-Json
$connectionString = [String]$deploymentOutputs.properties.outputs.azureCosmosDBAccountKeys.value
$setConnectionString = az webapp config appsettings set --name "${{ env.AZURE_WEBAPP_NAME }}" --resource-group "${{ env.AZURE_WEBAPP_NAME }}-rg" --settings CONNECTION_STRING="$connectionString"
$setAppSettings = az webapp config appsettings set --name "${{ env.AZURE_WEBAPP_NAME }}" --resource-group "${{ env.AZURE_WEBAPP_NAME }}-rg" --settings MSDEPLOY_RENAME_LOCKED_FILES=1
$setAppSettings = az webapp config appsettings set --name "${{ env.AZURE_WEBAPP_NAME }}" --resource-group "${{ env.AZURE_WEBAPP_NAME }}-rg" --settings SCM_DO_BUILD_DURING_DEPLOYMENT=true
$setAppSettings = az webapp config appsettings set --name "${{ env.AZURE_WEBAPP_NAME }}" --resource-group "${{ env.AZURE_WEBAPP_NAME }}-rg" --settings HEADER_VALUE="${{ secrets.MY_SECRET }}"
azPSVersion: "latest"

- name: 'Deploy to Azure WebApp'
uses: azure/webapps-deploy@v2
with:
app-name: ${{ env.AZURE_WEBAPP_NAME }}
package: ${{ env.AZURE_WEBAPP_PACKAGE_PATH }}

loadTest:
name: Load Test
needs: build-and-deploy
runs-on: ubuntu-latest
steps:
- name: Checkout GitHub Actions
Expand All @@ -78,7 +35,14 @@ jobs:
loadTestConfigFile: 'SampleApp.yaml'
loadTestResource: ${{ env.LOAD_TEST_RESOURCE }}
resourceGroup: ${{ env.LOAD_TEST_RESOURCE_GROUP }}

env: |
[
{
"name": "webapp",
"value": "${{env.ENDPOINT_URL}}"
}
]

- uses: actions/upload-artifact@v2
with:
name: loadTestResults
Expand Down
Loading