Skip to content

Instantly share code, notes, and snippets.

View goyalmohit's full-sized avatar

mohit goyal goyalmohit

  • Pune, India
View GitHub Profile
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.1.0",
"parameters": {
"firstArray": {
"type": "array",
"defaultValue": [
"1-1",
"1-2",
"1-3"
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"appServiceName": {
"type": "string",
"minLength": 1,
"maxLength": 10
},
"appServicePlanName": {
@goyalmohit
goyalmohit / Update-AssemblyInfoVersionFile.ps1
Last active February 20, 2024 19:25
Assembly versioning using PowerShell
function Update-AssemblyInfoVersionFile
{
Param
(
[Parameter(Mandatory=$true)]
[string]$productVersion
)
$buildNumber = $env:BUILD_BUILDNUMBER
if ($buildNumber -eq $null)
@goyalmohit
goyalmohit / create-azure-web-app-with-slot.json
Last active February 7, 2022 11:57
ARM template for creating azure web app along with a deployment slot
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"appServiceName": {
"type": "string",
"minLength": 1
},
"appServiceSkuName": {
"type": "string",
@goyalmohit
goyalmohit / create-azure-web-app-2.json
Created October 11, 2017 13:54
This is the ARM code to deploy Azure Web App with slots, app settings, properties and connection strings
{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"appServiceName": {
"type": "string",
"minLength": 1
},
"appServiceSkuName": {
"type": "string",
@goyalmohit
goyalmohit / install-octopus-using-powershell-dsc
Created November 25, 2017 21:47
Install and Configure Octopus Server using PowerShell DSC
Configuration SampleConfig
{
Import-DscResource -Module OctopusDSC
Node "localhost"
{
cOctopusServer OctopusServer
{
Ensure = "Present"
State = "Started"
@goyalmohit
goyalmohit / defining-msbuild-properties-project-file-samples-01
Last active December 3, 2017 13:56
Defining MSBuild Properties - Project File Samples 01
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<BuildDir>C:\Source\Repo\MyRepo\Bin</BuildDir>
</PropertyGroup>
</Project>
@goyalmohit
goyalmohit / defining-msbuild-properties-project-file-samples-02
Last active December 3, 2017 14:01
Defining MSBuild Properties - Project File Sample 02
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<BuildDir>C:\Source\Repo\MyRepo\Bin</BuildDir>
<Optimize>false</Optimize>
</PropertyGroup>
</Project>
@goyalmohit
goyalmohit / defining-msbuild-properties-project-file-samples-03
Last active December 3, 2017 14:04
Defining MSBuild Properties - Project File Sample 03
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<BuildDir>C:\Source\Repo\MyRepo\Bin</BuildDir>
</PropertyGroup>
<PropertyGroup>
<Optimize>false</Optimize>
</PropertyGroup>
</Project>
@goyalmohit
goyalmohit / defining-msbuild-properties-project-file-samples-04
Last active December 3, 2017 14:30
Defining MSBuild Properties - Project File Samples 04
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{974DF0E9-8535-4E6D-96DD-BF7CCF2B2480}</ProjectGuid>
<OutputType>Exe</OutputType>
<RootNamespace>ConsoleApp02</RootNamespace>
<AssemblyName>ConsoleApp02</AssemblyName>