{"id":13506885,"url":"https://github.com/Azure/azure-functions-powershell-worker","last_synced_at":"2025-03-30T05:31:28.968Z","repository":{"id":37271411,"uuid":"142599157","full_name":"Azure/azure-functions-powershell-worker","owner":"Azure","description":"PowerShell language worker for Azure Functions.","archived":false,"fork":false,"pushed_at":"2025-03-14T14:07:40.000Z","size":1653,"stargazers_count":209,"open_issues_count":161,"forks_count":54,"subscribers_count":60,"default_branch":"dev","last_synced_at":"2025-03-27T14:13:02.143Z","etag":null,"topics":["azure-functions","powershell"],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Azure.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-07-27T16:17:14.000Z","updated_at":"2025-03-17T00:21:28.000Z","dependencies_parsed_at":"2023-12-03T08:25:58.334Z","dependency_job_id":"2ecc35e6-cc8b-41ea-bdbc-aabc3073cc1b","html_url":"https://github.com/Azure/azure-functions-powershell-worker","commit_stats":{"total_commits":408,"total_committers":22,"mean_commits":"18.545454545454547","dds":0.6936274509803921,"last_synced_commit":"89e839959cee7fa77db5faf7379e3b43abce1d09"},"previous_names":[],"tags_count":98,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Azure%2Fazure-functions-powershell-worker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Azure%2Fazure-functions-powershell-worker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Azure%2Fazure-functions-powershell-worker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Azure%2Fazure-functions-powershell-worker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Azure","download_url":"https://codeload.github.com/Azure/azure-functions-powershell-worker/tar.gz/refs/heads/dev","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246281098,"owners_count":20752203,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["azure-functions","powershell"],"created_at":"2024-08-01T01:00:59.372Z","updated_at":"2025-03-30T05:31:28.947Z","avatar_url":"https://github.com/Azure.png","language":"C#","funding_links":[],"categories":["GitHub"],"sub_categories":[],"readme":"![azure-functions-logo][]\n\n|Branch|Status|\n|---|---|\n|dev|[![Build Status](https://dev.azure.com/azfunc/public/_apis/build/status%2Fazure%2Fazure-functions-powershell-worker%2Fpowershell-worker.public?repoName=Azure%2Fazure-functions-powershell-worker\u0026branchName=dev)](https://dev.azure.com/azfunc/public/_build/latest?definitionId=718\u0026repoName=Azure%2Fazure-functions-powershell-worker\u0026branchName=dev)|\n\n[azure-functions-logo]: https://raw.githubusercontent.com/Azure/azure-functions-cli/master/src/Azure.Functions.Cli/npm/assets/azure-functions-logo-color-raster.png\n\n# Azure Functions PowerShell Language Worker\n\nThis repository will host the PowerShell language worker implementation for Azure Functions.\nWe'll also be using it to track work items related to PowerShell support.\nPlease feel free to leave comments about any of the features and design patterns.\n\n## Overview\n\nPowerShell support for Functions is based on [PowerShell Core 7](https://github.com/powershell/powershell),\n[Functions on Linux](https://blogs.msdn.microsoft.com/appserviceteam/2017/11/15/functions-on-linux-preview/),\nand the [Azure Functions runtime V4](https://docs.microsoft.com/en-us/azure/azure-functions/functions-versions).\n\n## What's available?\n\n### Triggers / Bindings\n\n* HTTP Trigger (Webhook)\n* Timer Trigger\n* Blob Trigger\n* Queue Trigger\n\n## What's coming?\n\n* More triggers and bindings\n* Tooling integration\n* A bunch of other good things\n\n## Contributing\n\nThis project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).\nFor more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)\nor contact [opencode@microsoft.com](mailto:opencode@microsoft.com)\nwith any additional questions or comments.\n\n## Building from source\n\n### Prereqs\n\n* [.NET 8.0 SDK](https://www.microsoft.com/net/download/visual-studio-sdks)\n\n### Build\n\n1. Clone this repository\n2. `cd azure-functions-powershell-worker`\n3. `./build.ps1`\n\n\u003e NOTE: If you're missing a dependency,\nyou will be asked to run `./build.ps1 -Bootstrap`\n\n### Run \u0026 Debug\n\nThe PowerShell worker alone is not enough to establish the functions app, we also need the support from\n[Azure Functions Host](https://github.com/Azure/azure-functions-host).\nYou may either use a published host CLI or use the in-development host.\nBut both of the methods require you to attach to the .NET process if you want a step-by-step debugging experience.\n\n#### Published Host\n\nFirst, follow the [instructions to install the Azure Functions Core Tools](https://github.com/Azure/azure-functions-core-tools#installing).\nThen locate the `azure-functions-core-tools\\bin\\workers\\` folder.\nHere are a few hints on where it could be located:\n\nOn Windows if you installed via `npm`\n```\n~\\AppData\\Roaming\\npm\\node_modules\\azure-functions-core-tools\\bin\\workers\\\n```\nOn macOS if you installed via `brew`\n```\n/usr/local/Cellar/azure-functions-core-tools/\u003cversion\u003e/workers/\n```\n\nUnder the `workers/powershell` folder, create a folder with the name `7.4` if it does not exist yet. Copy the result of the `publish` directory into the `workers/powershell/7.4` folder, and copy the `publish/worker.config.json` file into the `workers/powershell` folder:\n```powershell\nCopy-Item -Recurse -Force ./src/bin/Debug/net8.0/publish/ \"/usr/local/Cellar/azure-functions-core-tools/$(func --version)/workers/powershell/7.4\"\nCopy-Item -Recurse -Force ./src/bin/Debug/net8.0/publish/worker.config.json \"/usr/local/Cellar/azure-functions-core-tools/$(func --version)/workers/powershell\"\n```\n\n\u003e NOTE: if the powershell folder already exists, you should delete it or debugging won't work.\n\nThen `cd` into a Function App with PowerShell as the worker runtime \n(NOTE: There's an example PowerShell Function App in the `examples` folder).\n\nSet the environment variable `FUNCTIONS_WORKER_RUNTIME_VERSION` to `7.4`, or add this as an app setting to the `local.settings.json` file.\n\nLastly, run:\n\n```\nfunc start\n```\n\n\u003e NOTE: If you would like to see more out of the logs, see the logging section in the\n[Azure Functions Host repo](https://github.com/Azure/azure-functions-host/wiki/Authoring-\u0026-Testing-Language-Extensions#logs).\n\n#### Latest Host\n\nA developer may also use the latest host code by cloning the git repository [Azure Functions Host](https://github.com/Azure/azure-functions-host).\nNow you need to navigate to the root folder of the host project and build it through:\n\n```sh\ndotnet restore WebJobs.Script.sln\ndotnet build WebJobs.Script.sln\n```\n\nAfter the build succeeded,\nset the environment variable `\"AzureWebJobsScriptRoot\"`\nto the root folder path (the folder which contains the `host.json`)\nof your test functions app.\n\nUnder the `workers/powershell` folder, create a folder with the name `7.4` if it does not exist yet. Then copy the `publish` directory to `workers/powershell/7.4`, and the `publish/worker.config.json` to `workers/powershell`:\n```powershell\nCopy-Item -Recurse -Force ./src/bin/Debug/net8.0/publish/ \"\u003cAzure Functions Host Root\u003e/src/WebJobs.Script.WebHost/bin/Debug/net8.0/workers/powershell/7.4\"\nCopy-Item -Force ./src/bin/Debug/net8.0/publish/worker.config.json \"\u003cAzure Functions Host Root\u003e/src/WebJobs.Script.WebHost/bin/Debug/net8.0/workers/powershell\"\n```\n\nThen you can start the host by running:\n```sh\ndotnet ./src/WebJobs.Script.WebHost/bin/Debug/net8.0/Microsoft.Azure.WebJobs.Script.WebHost.dll\n```\n\n\u003e Note: Remember to remove `\"AzureWebJobsScriptRoot\"`\nenvironment variable after you have finished debugging,\nbecause it will also influence the `func` CLI tool.\n\n### Packaging\n\nTo package the PowerShell Language Worker as a nupkg, do the following:\n\n* `cd azure-functions-powershell-worker`\n* `dotnet publish`\n* `cd package`\n* `dotnet pack`\n\nThat will place a `Microsoft.Azure.Functions.PowerShellWorker.*.nupkg` in:\n\n`azure-functions-powershell-worker/package/bin/Debug`\n\nIt pulls the contents of the publish folder in:\n\n`azure-functions-powershell-worker/src/bin/Debug/net8.0/publish`\n\nif you specify a different Configuration or TargetFramework that will be honored.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FAzure%2Fazure-functions-powershell-worker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FAzure%2Fazure-functions-powershell-worker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FAzure%2Fazure-functions-powershell-worker/lists"}