Skip to content

Instantly share code, notes, and snippets.

Avatar

Donovan Brown DarqueWarrior

View GitHub Profile
@DarqueWarrior
DarqueWarrior / launch.json
Created Aug 27, 2022
How to launch 3 Dapr services at the same time with debug enabled. You can set breakpoints in all three services and step from one to the other.
View launch.json
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"compounds": [
// For more information, visit: https://code.visualstudio.com/docs/editor/debugging#_compound-launch-configurations
{
"name": "All Services",
"preLaunchTask": "build",
@DarqueWarrior
DarqueWarrior / getK8sVersion.ps1
Created Aug 23, 2022
PowerShell Snippet: Using the Azure CLI to find the latest supported K8s version in a location. I use this to pass to my Bicep files to create an AKS with the latest version.
View getK8sVersion.ps1
Write-Output 'Finding version of K8s'
$location = 'eastus'
# Use index -1 to get the last entry which should be
# the latest version
$k8sversion = $(az aks get-versions --location $location `
--query orchestrators[-1].orchestratorVersion `
--output tsv)
Write-Verbose "k8s version = $k8sversion"
@DarqueWarrior
DarqueWarrior / development.js
Created Jun 11, 2022
Development section for truffle-config.js
View development.js
development: {
host: '127.0.0.1',
port: 8545,
network_id: '*'
}
@DarqueWarrior
DarqueWarrior / templatepack.csproj
Last active Jun 20, 2021
Skeleton of csproj file for packing a dotnet new template into a nuget package.
View templatepack.csproj
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<Title></Title>
<Authors></Authors>
<Description></Description>
<PackageId></PackageId>
<PackageTags></PackageTags>
<PackageType>Template</PackageType>
<PackageVersion>1.0</PackageVersion>
<TargetFramework>netcoreapp3.1</TargetFramework>
@DarqueWarrior
DarqueWarrior / Deploy-AzureResourceGroup.ps1
Created Feb 3, 2019
Updated Deploy-AzureResourceGroup.ps1 to use Az PowerShell module
View Deploy-AzureResourceGroup.ps1
#Requires -Version 6.0
Param(
[string] [Parameter(Mandatory=$true)] $ResourceGroupLocation,
[string] $ResourceGroupName = 'AppServiceAndSql',
[switch] $UploadArtifacts,
[string] $StorageAccountName,
[string] $StorageContainerName = $ResourceGroupName.ToLowerInvariant() + '-stageartifacts',
[string] $TemplateFile = 'WebSiteSQLDatabase.json',
[string] $TemplateParametersFile = 'WebSiteSQLDatabase.parameters.json',