Skip to content

v3: Intermittent "No subscriptions found" failure with OIDC login despite subscription-id being provided #592

@AdmirMuric

Description

@AdmirMuric

When using azure/login@v3 with OIDC (federated credentials) and an explicit subscription-id input, the action intermittently fails with:

Error: No subscriptions found for ***.
Error: Login failed with Error: The process 'C:\Program Files\Microsoft SDKs\Azure\CLI2\wbin\az.cmd' failed with exit code 1. Double check if the 'auth-type' is correct. Refer to https://github.com/Azure/login#readme for more information.

Current behavior

The failure is non deterministic, the same workflow, same SP, same subscription succeeds in parallel jobs within the same run but fails on some.

Expected

When subscription-id is explicitly provided, the action should not fail due to empty subscription enumeration. The subscription ID is already known, there's no need to require successful enumeration before calling az account set.

Potential workaround

Make use of allow-no-subscriptions: true, se explanation of it #592 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions