Deploy to azure functions using powershell -
is there way, can deploy azure functions using powershell scripts? ci not work because use octopus deploy deploy of our production services. beneficial if there way deploy using powershell scripts.
thanks!
you can deploy functions azure using kudu rest api. can see code/samples of doing in our templates repository. in this code sample, can see how our test script calls out kudu rest apis deploy zip function app.
the folder structure functions function per folder. need deploy function folders ./site/wwwroot
on function app. need add app settings might contain secrets if add new bindings between updates.
the powershell code along lines of:
$apiurl = $config.scmendpoint + "/api/zip/" if ($destinationpath) { $apiurl = $apiurl + $destinationpath } $response = invoke-restmethod -uri $apiurl -headers @{authorization=("basic {0}" -f $config.authinfo)} -method put -infile $zipfilepath -contenttype "multipart/form-data"
Comments
Post a Comment