Giter VIP home page Giter VIP logo

github-azure-function-proxy-for-arm-template's Introduction

GitHub-Azure-Function-Proxy-for-ARM-Template

ARM templates expect a public URL to download your templates. This allows you to use your private GitHub repo for Azure Linked ARM templates. The Azure Function is basically a proxy to GitHub. You can edit the Azure Function for your source control provider of choice.

Create the Azure Function

  1. Create an Azure Function of type .NET named {Organization}GitHubProxy (the function name needs to be globally unique)
  2. Paste the Azure-Function.cs into a new function
  3. Login into GitHub
    • Click on your name (top right)
    • Select Settings
    • Go to Developer Settings
    • Go to Personal Access Token
    • Click Generate New Token
    • Give it name
    • Select repo scope access
  4. Paste your Personal Access Token into the Azure Function
    • string personalAcccessToken = "{REMOVED}";

To call the Azuze Function

To Run via command line (Linux)

  • You need to change the URL in the azuredeploy.json
# Login
az login

# Select Subscription
az account set -s REPLACE_ME

# Script parameters
resourceGroup="Azure-Function-Proxy"
location="eastus"
today=`date +%Y-%m-%d-%H-%M-%S`
deploymentName="MyDeployment-$today"

# Create resource group
az group create \
  --name        $resourceGroup \
  --location    $location

# Deploy the ARM template
az group deployment create \
  --name                 $deploymentName \
  --resource-group       $resourceGroup \
  --template-file        azuredeploy.json

# Clean up resource group
az group delete --name $resourceGroup

github-azure-function-proxy-for-arm-template's People

Contributors

adampaternostro avatar patpicos avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.