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

Implement pipeform for Terraform Operations #926

Open
3 tasks
osterman opened this issue Jan 10, 2025 · 1 comment
Open
3 tasks

Implement pipeform for Terraform Operations #926

osterman opened this issue Jan 10, 2025 · 1 comment

Comments

@osterman
Copy link
Member

osterman commented Jan 10, 2025

Describe the Feature

Improve the console DX of terraform operations by presenting the user with a friendly UI to show terrafom progress.

https://github.com/magodo/pipeform

Expected Behavior

Running atmos terraform plan and atmos terraform apply will launch the pipeform UI. Note, this does not require pipeform to be installed, as it will be used as a native Go module.

Use Case

On the command line, the output from terraform is overwhelming and doesn't convey the overall progress of the operation. Terraform will feel much friendlier if we present the user with a progress indicator.

Describe Ideal Solution

The UI would be enabled by default, but can be disabled via the atmos.yaml configuration.

# atmos.yaml
terraform:
  ui:
    enable: [plan, apply]
pipeform.mp4

Requirements:

  • If no TTY is attached, the UI should be automatically disabled
  • If the CI=true environment variable is set, then UI should be automatically disabled
  • If the --no-ui flag is explicitly passed, then the UI should be disabled.

Alternatives Considered

No response

Additional Context

The pipeform library is licensed MPL2 and is not currently implemented as a Go module. We've contacted the @magodo (author) and he said he would accept a PR converting it to a library. As part of this implementation, we will need to first open a PR for that work.

@suzuki-shunsuke
Copy link
Contributor

pipeform is interesting, but honestly I'm not sure if we should really use this by default.
I tried pipeform a bit.
When we use pipeform, the plan result doesn't output in the terminal.

$ terraform plan -json | pipeform
# No output

I think this is inconvenient.
I'm not sure if we can convert the output of terraform plan -json to the conventional terraform output.

Furthermore, seems like we can't show the detail of changes.
I expected that we can choose a resource and show its detail, but seems like we can't.

image

By the way, the final view of terraform plan -json | pipeform looks strange.
I think we can contribute to pipeform.

image

pipeform shows nothing. This confused me.
I found I needed to move page by h and l key.

image

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

No branches or pull requests

2 participants