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

Allow importing a parent and child resource at the same time #14461

Merged
merged 1 commit into from Nov 10, 2023

Conversation

Frassle
Copy link
Member

@Frassle Frassle commented Oct 31, 2023

Description

Allow pulumi import to import one resource and then use that resource as a parent for another imported resource.

Currently parents can only refer to resources that already exist in the deployment meaning if you want to do this today you have to do two imports.

Checklist

  • I have run make tidy to update any new dependencies
  • I have run make lint to verify my code passes the lint check
    • I have formatted my code using gofumpt
  • I have added tests that prove my fix is effective or that my feature works
  • I have run make changelog and committed the changelog/pending/<file> documenting my change
  • Yes, there are changes in this PR that warrants bumping the Pulumi Cloud API version

@pulumi-bot
Copy link
Contributor

pulumi-bot commented Oct 31, 2023

Changelog

[uncommitted] (2023-10-31)

Features

  • [engine] import can now import a parent resource in the same deployment as a child resource.
    #14461

@Frassle Frassle force-pushed the fraser/importParent branch 2 times, most recently from a465df8 to 38d4a9a Compare October 31, 2023 17:01
@Frassle Frassle requested a review from a team October 31, 2023 17:11
Copy link
Member

@justinvp justinvp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Frassle Frassle added this pull request to the merge queue Nov 10, 2023
Merged via the queue into master with commit cfe8165 Nov 10, 2023
44 checks passed
@Frassle Frassle deleted the fraser/importParent branch November 10, 2023 14:07
github-merge-queue bot pushed a commit that referenced this pull request Nov 14, 2023
### Features

- [engine] `import` can now create empty component resource to use as
the parent of other imported resources.
  [#14467](#14467)

- [engine] `import` can now import a parent resource in the same
deployment as a child resource.
  [#14461](#14461)

- [engine] Import files no longer need parent URNs in the name table for
resource being imported in the same file.

- [cli/config] `config refresh` will now restore secret provider config
from the last deployment.
  [#13900](#13900)

- [cli/new] Simplifies URL parsing for pulumi new zip
  [#14546](#14546)


### Bug Fixes

- [components/yaml] Upgrade yaml to 1.4.1
  [#14542](#14542)

- [engine] Ignore spurious error from Kubernetes providers DiffConfig
method.
  [#14533](#14533)
@justinvp justinvp mentioned this pull request Nov 14, 2023
github-merge-queue bot pushed a commit that referenced this pull request Nov 15, 2023
### Features

- [engine] `import` can now create empty component resource to use as
the parent of other imported resources.
  [#14467](#14467)

- [engine] `import` can now import a parent resource in the same
deployment as a child resource.
  [#14461](#14461)

- [engine] Import files no longer need parent URNs in the name table for
resource being imported in the same file.
  [#14524](#14524)

- [cli/config] `config refresh` will now restore secret provider config
from the last deployment.
  [#13900](#13900)

- [cli/new] Simplifies URL parsing for pulumi new zip
  [#14546](#14546)


### Bug Fixes

- [components/yaml] Upgrade yaml to 1.4.1
  [#14542](#14542)

- [engine] Ignore spurious error from Kubernetes providers DiffConfig
method.
  [#14533](#14533)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants