Skip to content

Instantly share code, notes, and snippets.

@mikhailshilkov
Created April 4, 2019 15:29
Show Gist options
  • Save mikhailshilkov/3beae3ede35435d66861b3fbc97548db to your computer and use it in GitHub Desktop.
Save mikhailshilkov/3beae3ede35435d66861b3fbc97548db to your computer and use it in GitHub Desktop.
open System
open Pulumi
open Components
open Common
open Cosmos
open FunctionApp
module Program =
let app () =
let rg = resourceGroup {
name "urlshort-rg"
region WestUS
}
let zipStorage = storageAccount {
name "urlshortsa"
resourceGroup rg
}
let cosmos = cosmosdb {
name "urlshort-cosmos"
resourceGroup rg
database "mydb"
collection "myitems"
}
functionApp {
name "fsharpfa"
package "..\\Functions\\bin\\Debug\\netcoreapp2.1\\Functions.zip"
version V2
runtime DotNet
resourceGroup rg
storageAccount zipStorage
cosmosdb cosmos
}
[<EntryPoint>]
let Main (_: string[]) =
Runtime.Run(Action (app >> ignore))
0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment