Azure / Azure/azure-dev

Support `run from package` for function and web apps

Open
#3,162 5 comments 0 reactions 0 assignees View on GitHub
area/functions customer-reported feature needs-team-attention
Dominant language
Go
Stars
569
Forks
364
Avg merge
2d 22h
Merged PRs (30d)
139

Description

- [x] Make sure you've installed the latest version using [instructions in the wiki](../wiki/install)

**Output from `azd version`**
Run `azd version` and copy and paste the output here:
azd version 1.5.1 (commit 3856d1e98281683b8d112e222c0a7c7b3e148e96)

**Describe the bug**
Deploying an Azure Function in dotnet 8 isolated doesn't work from a Linux machine.

**To Reproduce**
1. Clone the following [repo](https://github.com/xaviermignot/azd-afa-dotnet).
2. Run `azd up` from the root of the repo
3. Check the _Overview_ panel of the Function App from the portal, no function has been deployed.

**Expected behavior**
We should see a `HelloWorldFunction` in the list of deployed functions. Deploying from vs code works fine.

**Environment**
Information on your environment:
* Language name and version: C#, dotnet isolated 8
* IDE and version : Visual Studio Code 1.85.1

**Additional context**
I guess my problem is related to the "run from a package" feature as described [here](https://learn.microsoft.com/en-us/azure/azure-functions/run-functions-from-deployment-package#enable-functions-to-run-from-a-package) in the docs.
Deploying from vs code adds the `WEBSITE_RUN_FROM_PACKAGE` setting to my Function App with a URL to a zip file in my storage account. I don't manage this setting in my Bicep code, I was expecting `azd` to handle it as vs code does (but it might be wrong).

The package created by `azd` in the `/tmp` folder looks correct.

I have also tried to use a file share (with the `WEBSITE_CONTENTAZUREFILECONNECTIONSTRING` and `WEBSITE_CONTENTSHARE` settings) but no content is pushed to the file share when deploying (except the `host.json` file).

Has anyone already deployed to a Linux Azure Function in .NET 8 isolated using `azd` ? I would like to know which method is supported, if any. I haven't found information about this in the docs, sorry if I missed it.
I am open to workarounds/suggestions, if there is anything I should try, please tell me !

Thanks and happy holidays !

Contributor guide

Open the contributing guide

Research direction

Start with the azd up deployment path for the reproduced Azure Function project and compare it with the VS Code deployment behavior described in the issue. Check how the generated package and WEBSITE_RUN_FROM_PACKAGE setting are handled on Linux. Done means azd up deploys the HelloWorldFunction and it appears in the Function App overview.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
cloud, devops
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.