Skip to content

Instantly share code, notes, and snippets.

View NenoLoje's full-sized avatar

Neno Loje NenoLoje

View GitHub Profile
@NenoLoje
NenoLoje / SmokeTest.ps1
Created April 24, 2024 12:26
PowerShell script to check HTTP status code and for an expected string
param
(
[Parameter(Mandatory=$True,Position=1)]
[string]$url,
[Parameter(Mandatory=$True,Position=2)]
[string]$expectedString
)
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
@NenoLoje
NenoLoje / azure-pipelines.yml
Created April 24, 2024 11:59
Binding syntax for IISWebAppManagementOnMachineGroup@0
steps:
- task: IISWebAppManagementOnMachineGroup@0
displayName: 'Configure IIS'
inputs:
EnableIIS: true
IISDeploymentType: 'IISWebsite'
ActionIISWebsite: 'CreateOrUpdateWebsite'
WebsiteName: '$(iisWebsite)'
WebsitePhysicalPath: '%SystemDrive%\inetpub\wwwroot\$(iisWebsite)'
WebsitePhysicalPathAuth: 'WebsiteUserPassThrough'
@NenoLoje
NenoLoje / azure-pipelines.yml
Created December 13, 2023 21:33
Azure Pipelines: Repeat a step multiple times (using `each`)
parameters:
- name: listOfStrings
displayName: 'List of strings'
type: object
default:
- one
- two
- three
steps:
@NenoLoje
NenoLoje / azure-pipelines.yml
Last active December 13, 2023 21:36
Azure Pipelines: Build a SSDT Database Project (SQL Server Data Tools)
parameters:
- name: solutionFile
type: string
- name: projectName
type: string
- name: buildConfiguration
type: string
default: 'Release'
variables:
@NenoLoje
NenoLoje / azurepipelines-coverage.yml
Created January 9, 2020 15:14
This file is used to configure Code Coverage for Pull Requests on Azure DevOps: https://docs.microsoft.com/en-us/azure/devops/pipelines/test/codecoverage-for-pullrequests
# This file needs to be in the root of a repo.
coverage:
status:
comments: on
diff:
target: 70%
@NenoLoje
NenoLoje / azure-pipelines.yml
Created October 28, 2019 18:14
[Azure Pipelines] Sample Pipeline #3 for node.js app with multiple deployment stages (from code.talks 2019 demo)
# Node.js
# Build a general Node.js project with npm.
# Add steps that analyze code, save build artifacts, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
trigger:
- master
stages:
- stage: Build
@NenoLoje
NenoLoje / azure-pipelines.yml
Last active October 28, 2019 18:15
[Azure Pipelines] Sample Pipeline #2 for node.js app with a deployment stage (from code.talks 2019 demo)
# Node.js
# Build a general Node.js project with npm.
# Add steps that analyze code, save build artifacts, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
trigger:
- master
stages:
- stage: Build
@NenoLoje
NenoLoje / azure-pipelines.yml
Last active October 28, 2019 18:09
[Azure Pipelines] Sample Pipeline #1 for node.js app, build stage only (from code.talks 2019 demo)
# Node.js
# Build a general Node.js project with npm.
# Add steps that analyze code, save build artifacts, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/javascript
trigger:
- master
pool:
vmImage: 'windows-latest' # or: 'ubuntu-latest'