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

Display resource source in JSON output #874

Closed
eliecharra opened this issue Jul 23, 2021 · 1 comment
Closed

Display resource source in JSON output #874

eliecharra opened this issue Jul 23, 2021 · 1 comment
Assignees
Labels
kind/maintenance Refactoring or changes to the workspace priority/3

Comments

@eliecharra
Copy link
Contributor

eliecharra commented Jul 23, 2021

Description
We want to display resource source in JSON output

Example

"differences": [
    {
        "res": {
            "id": "diff-id-1",
            "type": "aws_diff_resource",
            "source": {
                "module": "module.dev_dynamodb_from_omaha_role",
                "name": "main",
                "state": "s3://terraform-state-bucket/accounts/foo.tfstate"
            },
        },

Blocked by #873

@eliecharra eliecharra added kind/maintenance Refactoring or changes to the workspace kind/blocked need-triage labels Jul 23, 2021
@eliecharra eliecharra added this to Triage in driftctl via automation Jul 23, 2021
@moadibfr moadibfr moved this from Triage to Ready To Develop in driftctl Jul 23, 2021
@moadibfr moadibfr assigned moadibfr and unassigned moadibfr Jul 23, 2021
@eliecharra eliecharra self-assigned this Aug 2, 2021
@eliecharra eliecharra moved this from Ready To Develop to In Progress in driftctl Aug 2, 2021
@eliecharra eliecharra moved this from In Progress to Review in driftctl Aug 6, 2021
@eliecharra eliecharra assigned sjourdan and unassigned eliecharra Aug 6, 2021
@sjourdan
Copy link
Contributor

sjourdan commented Sep 3, 2021

LGTM

for a missing resource:

  "missing": [
    {
      "id": "driftctl-qa-s3-bucket-2",
      "type": "aws_s3_bucket",
      "source": {
        "source": "tfstate://2/terraform.tfstate",
        "namespace": "",
        "internal_name": "two"
      }
    }
  ],

for a changed resource (deep)

 "differences": [
    {
      "res": {
        "id": "driftctl-qa-s3-bucket-1",
        "type": "aws_s3_bucket",
        "source": {
          "source": "tfstate://1/terraform.tfstate",
          "namespace": "",
          "internal_name": "one"
        }
      },

for a working managed resource

    {
      "id": "driftctl-qa-s3-bucket-3",
      "type": "aws_s3_bucket",
      "source": {
        "source": "tfstate://3/terraform.tfstate",
        "namespace": "",
        "internal_name": "three"
      }
    }

@sjourdan sjourdan closed this as completed Sep 3, 2021
driftctl automation moved this from Review to Done Sep 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/maintenance Refactoring or changes to the workspace priority/3
Projects
None yet
Development

No branches or pull requests

3 participants