8000 Import externally created resources into declared resources · Issue #81 · nixops4/nixops4 · GitHub
[go: up one dir, main page]

Skip to content

Import externally created resources into declared resources #81

Description

@roberth

In the real-world exist a lot of resources that have been created by other tools, and UIs.
Add functionality to nixops4 to make it easy to bring these under the management of nixops4 without first deleting them or doing risky manual state edits.

This may serve as a more general alternative to #80, and might be a good preparation for that or even a prerequisite.

Compare OpenTofu Import

Add a 👍 reaction if you find this feature important

Activity

  1. t3dodson commented on Dec 28, 2025

    @t3dodson

    Curious if this feature could allow for Read, but not Create, Update, Delete?

    I'm thinking there could be benefit to gradually integrating existing infra to nixops in scenarios where we cannot/will not be able to fully have it managed by nixops.

    Trying to contrive an example. Maybe our MX dns record is established outside of nixops, and it would be a lot of effort to have it managed by nixops, however I could still see a benefit to being able to read it and used in other resources.

  2. roberth commented on Dec 28, 2025

    @roberth
    ContributorAuthor

    In terraform, what you're describing would be modeled with a "data source", which is a lot like a resource but can only be read from, having no C/U/D operations.

    Both use cases are valid, and I think both should be implemented.

    • importing for when you want NixOps4 to manage it, read-write
    • some sort of read only resource parameter for when you don't

    I've opened #133 to discuss the latter solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0