Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in documentation for importing service principal #1750

Closed
nicro950 opened this issue Jan 6, 2025 · 2 comments
Closed

Error in documentation for importing service principal #1750

nicro950 opened this issue Jan 6, 2025 · 2 comments
Labels
area/docs Improvements or additions to documentation area/import An issue related to `pulumi import` or the import resource option. kind/bug Some behavior is incorrect or out of spec resolution/fixed This issue was fixed

Comments

@nicro950
Copy link

nicro950 commented Jan 6, 2025

Describe what happened

If I follow the documentation for importing a service principal, https://www.pulumi.com/registry/packages/azuread/api-docs/serviceprincipal/#import, then i get a problem with that it does not find the resource. It looks like ServicePrincipal also have got the new id format that Application has, and the import worked when i tried to import /servicePrincipals/{objectId} instead.

Sample program

Try using the pulumi import azuread:index/servicePrincipal:ServicePrincipal example 00000000-0000-0000-0000-000000000000 import command for importing a service principal.

Using pulumi import azuread:index/servicePrincipal:ServicePrincipal example /servicePrincipals/00000000-0000-0000-0000-000000000000 instead does import the resource

Log output

Diagnostics:
pulumi:pulumi:Stack ():
error: preview failed

azuread:index:ServicePrincipal (oasis-dev-appreg-sp):
error: Preview failed: resource '{Object Id}' does not exist

Affected Resource(s)

No response

Output of pulumi about

CLI
Version 3.144.1
Go Version go1.23.4
Go Compiler gc

Host
OS Microsoft Windows 11 Enterprise
Version 10.0.22631 Build 22631
Arch x86_64

Backend
Name ...
URL azblob://...
User ...
Organizations
Token type personal

Additional context

No response

Contributing

Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

@nicro950 nicro950 added kind/bug Some behavior is incorrect or out of spec needs-triage Needs attention from the triage team labels Jan 6, 2025
@thomas11
Copy link
Contributor

thomas11 commented Jan 7, 2025

Thank you for reporting this, @nicro950! Something seems to be going wrong when we process the TF docs. I've shared the issue internally and we'll see if we can fix it soon.

@thomas11 thomas11 added area/docs Improvements or additions to documentation area/import An issue related to `pulumi import` or the import resource option. and removed needs-triage Needs attention from the triage team labels Jan 7, 2025
@thomas11 thomas11 added the resolution/fixed This issue was fixed label Jan 21, 2025
@thomas11
Copy link
Contributor

The latest release v6.2.0 fixes this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/docs Improvements or additions to documentation area/import An issue related to `pulumi import` or the import resource option. kind/bug Some behavior is incorrect or out of spec resolution/fixed This issue was fixed
Projects
None yet
Development

No branches or pull requests

2 participants