microsoft / microsoft/aspire

Azure Function resources get 'Failed to execute command 'rebuild' on resource' error

Open
#16,029 0 comments 0 reactions 0 assignees View on GitHub
area-integrations azure-functions
Dominant language
C#
Stars
6.3k
Forks
991
Avg merge
2d 15h
Merged PRs (30d)
196

Description

### Is there an existing issue for this?

- [x] I have searched the existing issues

### Describe the bug

If an Azure Function is added to an AppHost, it can't be rebuilt using the `rebuild` commmand

### Expected Behavior

It should rebuild like other resources

### Steps To Reproduce

1. Create new Azure Function application
2. Add it to Aspire/AppHost
3. Name the resource 'func'
4. `aspire run`
5. enter `aspire resource func rebuild`
6. Notice error message

> Failed to execute command 'rebuild' on resource 'func ': Rebuilder resource for 'func ' not found.

### Exceptions (if any)

resource is rebuilt

### Aspire doctor output

Checking Aspire environment...

Aspire Environment Check
========================

.NET SDK
✔ .NET 10.0.201 installed (x64)

Container Runtime
⚠ Docker Desktop is installed but not running
Start Docker Desktop
See: https://aka.ms/dotnet/aspire/containers

Environment
✔ HTTPS development certificate is trusted

Summary: 2 passed, 1 warnings, 0 failed
For detailed prerequisites: https://aka.ms/aspire-prerequisites

### Anything else?

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.