Skip to content

Commit

Permalink
gpsup
Browse files Browse the repository at this point in the history
  • Loading branch information
oskogstad committed Dec 5, 2024
1 parent 9c2c876 commit 569d267
Show file tree
Hide file tree
Showing 12 changed files with 37 additions and 37 deletions.
2 changes: 1 addition & 1 deletion .azure/modules/applicationInsights/availabilityTest.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ param timeout int = 60 // Default is 1 minute
resource availabilityTest 'Microsoft.Insights/webtests@2022-06-15' = {
name: name
location: location
tags: union(tags, {
tags: union(tags, {
'hidden-link:${appInsightsId}': 'Resource'
})
kind: 'standard'
Expand Down
2 changes: 1 addition & 1 deletion .azure/modules/keyvault/copySecrets.bicep
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*
/*
This module copies secrets from a source Key Vault to a destination Key Vault and adds references to those secrets in App Configuration.
*/
// Source
Expand Down
2 changes: 1 addition & 1 deletion .azure/modules/managedIdentity/main.bicep
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ resource managedIdentity 'Microsoft.ManagedIdentity/userAssignedIdentities@2023-
}

output managedIdentityId string = managedIdentity.id
output managedIdentityPrincipalId string = managedIdentity.properties.principalId
output managedIdentityPrincipalId string = managedIdentity.properties.principalId
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ resource roleAssignment 'Microsoft.Authorization/roleAssignments@2022-04-01' = [
principalId: principalId
principalType: 'ServicePrincipal'
}
}]
}]
4 changes: 2 additions & 2 deletions .azure/modules/serviceBus/main.bicep
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// This Bicep module provisions a Service Bus namespace with a Premium SKU in Azure,
// assigns a system-managed identity, and sets up a private endpoint for secure connectivity.
// This Bicep module provisions a Service Bus namespace with a Premium SKU in Azure,
// assigns a system-managed identity, and sets up a private endpoint for secure connectivity.
// It also configures a private DNS zone for the Service Bus namespace to facilitate network resolution within the virtual network.
import { uniqueResourceName } from '../../functions/resourceName.bicep'

Expand Down
26 changes: 13 additions & 13 deletions .github/pr-title-checker-config.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"LABEL": {
"name": "title needs formatting",
"color": "EEEEEE"
},
"CHECKS": {
"regexp": "^(feat|fix|docs|test|ci|chore)!?(\\(.*\\))?!?:.*"
},
"MESSAGES": {
"success": "PR title is valid",
"failure": "PR title is invalid",
"notice": "PR Title needs to pass regex '^(feat|fix|docs|test|ci|chore)!?(\\(.*\\))?!?:.*"
}
}
"LABEL": {
"name": "title needs formatting",
"color": "EEEEEE"
},
"CHECKS": {
"regexp": "^(feat|fix|docs|test|ci|chore)!?(\\(.*\\))?!?:.*"
},
"MESSAGES": {
"success": "PR title is valid",
"failure": "PR title is invalid",
"notice": "PR Title needs to pass regex '^(feat|fix|docs|test|ci|chore)!?(\\(.*\\))?!?:.*"
}
}
10 changes: 5 additions & 5 deletions .github/tools/containerAppJobVerifier.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,25 +31,25 @@ echo " "

verify_job_succeeded() {
local current_job_execution

current_job_execution=$(az containerapp job execution list -n "$job_name" -g "$resource_group" --query "$query_filter" 2>/dev/null)

if [ -z "$current_job_execution" ]; then
echo "No job execution found for job $job_name"
return 1
fi

current_job_execution_name=$(echo $current_job_execution | jq -r '.name')
current_job_execution_status=$(echo $current_job_execution | jq -r '.status')

echo "Container: $current_job_execution_name"
echo "Running status: $current_job_execution_status"

# Check job execution status
if [[ $current_job_execution_status == "Succeeded" ]]; then
return 0 # OK!
elif [[ $current_job_execution_status == "Failed" ]]; then
echo "Job execution failed. Exiting script."
echo "Job execution failed. Exiting script."
exit 1
else
return 1 # Not OK!
Expand All @@ -71,4 +71,4 @@ while true; do
echo "Attempt $attempt: Waiting for job $job_name ..."
sleep 10 # Sleep for 10 seconds
fi
done
done
8 changes: 4 additions & 4 deletions .github/tools/pwdGenerator.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ function Get-RandomCharacters([int]$length, [string]$characters) {
$private:ofs=""
return [string]$characters[$random]
}
function Scramble-String([string]$inputString){
$characterArray = $inputString.ToCharArray()
$scrambledStringArray = $characterArray | Get-Random -Count $characterArray.Length
function Scramble-String([string]$inputString){
$characterArray = $inputString.ToCharArray()
$scrambledStringArray = $characterArray | Get-Random -Count $characterArray.Length
$outputString = -join $scrambledStringArray
return $outputString
return $outputString
}
function GeneratePassword{
param(
Expand Down
2 changes: 1 addition & 1 deletion .github/tools/revisionVerifier.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ attempt=1
while true; do
verify_revision
result=$?

case $result in
$EXIT_SUCCESS)
echo "Revision $revision_name is healthy and running"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci-cd-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
get-current-version:
name: Get current version
uses: ./.github/workflows/workflow-get-current-version.yml

dry-run-deploy-infra:
name: Dry run deploy infra to prod
if: ${{ github.event_name == 'workflow_dispatch' || needs.check-for-changes.outputs.hasInfraChanges == 'true' }}
Expand Down Expand Up @@ -103,7 +103,7 @@ jobs:
version: ${{ needs.get-current-version.outputs.version }}
dryRun: true
runMigration: ${{ github.event_name == 'workflow_dispatch' || needs.check-for-changes.outputs.hasMigrationChanges == 'true' }}

deploy-apps:
name: Deploy apps to prod
needs:
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/workflow-run-k6-performance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
inputs:
apiVersion:
required: true
type: string
type: string
environment:
required: true
type: string
Expand All @@ -20,7 +20,7 @@ on:
type: string
tokens:
required: true
type: string
type: string
secrets:
TOKEN_GENERATOR_USERNAME:
required: true
Expand Down Expand Up @@ -48,11 +48,11 @@ jobs:
./tests/k6/tests/scripts/generate_tokens.sh ./tests/k6/tests/performancetest_data ${{ inputs.tokens }}
k6 run ${{ inputs.testSuitePath }} --quiet --log-output=stdout --include-system-env-vars \
--vus=${{ inputs.vus }} --duration=${{ inputs.duration }} --out=cloud --out csv=./results.csv
grep http_req_duration ./results.csv | sort --field-separator=',' --key=3 -nr | head -10
grep http_req_duration ./results.csv | sort --field-separator=',' --key=3 -nr | head -10
env:
API_ENVIRONMENT: ${{ inputs.environment }}
API_VERSION: ${{ inputs.apiVersion }}
TOKEN_GENERATOR_USERNAME: ${{ secrets.TOKEN_GENERATOR_USERNAME }}
TOKEN_GENERATOR_PASSWORD: ${{ secrets.TOKEN_GENERATOR_PASSWORD }}
TOKEN_GENERATOR_PASSWORD: ${{ secrets.TOKEN_GENERATOR_PASSWORD }}
K6_CLOUD_TOKEN: ${{ secrets.K6_CLOUD_TOKEN }}
K6_CLOUD_PROJECT_ID: ${{ secrets.K6_CLOUD_PROJECT_ID }}
4 changes: 2 additions & 2 deletions .github/workflows/workflow-run-k6-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
inputs:
apiVersion:
required: true
type: string
type: string
environment:
required: true
type: string
Expand Down Expand Up @@ -40,7 +40,7 @@ jobs:
API_ENVIRONMENT: ${{ inputs.environment }}
API_VERSION: ${{ inputs.apiVersion }}
TOKEN_GENERATOR_USERNAME: ${{ secrets.TOKEN_GENERATOR_USERNAME }}
TOKEN_GENERATOR_PASSWORD: ${{ secrets.TOKEN_GENERATOR_PASSWORD }}
TOKEN_GENERATOR_PASSWORD: ${{ secrets.TOKEN_GENERATOR_PASSWORD }}

- name: Store test summary
uses: actions/upload-artifact@v4
Expand Down

0 comments on commit 569d267

Please sign in to comment.