Azure / Azure/azure-functions-core-tools

Inability to refresh triggers behind authenticated function app post deploy

Open
#4,196 2 comments 0 reactions 0 assignees View on GitHub
needs-investigation potential-bug
Dominant language
C#
Stars
1.5k
Forks
498
Avg merge
4d 20h
Merged PRs (30d)
14

Description

### Version

4.0.6610

### Description

Unable to sync triggers on Function App protected by OpenID auth (Azure AD B2C tenant) - 401

Unable to pass a seperate access token for the refresh trigger step, as the access token is used for publish as well as the refresh step. Unable to split the refresh step off and call it seperately with a different access token. (Both would be potential solutions, although I guess so would adding another auth provider!)

### Steps to reproduce

Deploy function app with OpenID "required" auth configured.
Tooling is unable to refresh the triggers, as is unable to auth.

Log:

[SyncTriggerStep] starting.
Waiting 60 seconds for the workers to recycle with deployed content.
[CleanUpStep] starting.
Cleaned the source packages directory.
Cleaned the result artifact directory.
Finished deployment pipeline.
FunctionHostSyncTrigger, statusCode = Unauthorized
Deployment was successful but the app appears to be unhealthy, please check the app logs.
Checking the app health...................

Contributor guide

Open the contributing guide

Research direction

Start with the deployment path around SyncTriggerStep and the FunctionHostSyncTrigger call shown in the log. Reproduce the deployment against a Function App with OpenID authentication required, then trace how the publish token is reused for trigger refresh. Done means protected apps refresh triggers successfully without breaking the existing publish step.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, csharp
Domain
authentication, cli, cloud
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.