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

Support Terraform's --target flag #129

Closed
so0k opened this issue Aug 17, 2017 · 4 comments
Closed

Support Terraform's --target flag #129

so0k opened this issue Aug 17, 2017 · 4 comments
Assignees

Comments

@so0k
Copy link
Contributor

so0k commented Aug 17, 2017

I haven't tried this out yet, but is it possible to specify resource targets with --target? We use this heavily when making infrastructure updates

@lkysow
Copy link
Collaborator

lkysow commented Aug 17, 2017

@so0k you can append flags to any terraform command (ex. plan, apply) using the extra_arguments configuration key in an atlantis.yaml config file living in your project (see https://github.com/hootsuite/atlantis#project-specific-customization).

So you could have

# atlantis.yaml
extra_arguments:
- command: plan
  arguments:
  - "-target=TARGET"

But does it make sense to set this against an entire project or on different plan/apply runs do you need to set a target? In which case you'd like -target to be an option to the atlantis plan and atlantis apply commands?

@nwalke
Copy link

nwalke commented Aug 17, 2017

Reading -target in from a PR comment would be ideal for us.

@so0k
Copy link
Contributor Author

so0k commented Aug 17, 2017

Same as nwalke, we often just want to plan and apply just one module (and each PR can be a different module)

@anubhavmishra
Copy link
Collaborator

We might try out by having an terraform plan/apply argument passed down from the comment during plan or apply. For example atlantis plan -target=something or atlantis plan -refresh=true

@lkysow lkysow self-assigned this Aug 19, 2017
lkysow added a commit that referenced this issue Aug 23, 2017
New parsing of comments. Accept all flags. Fixes #129
malnick pushed a commit to BlueOwlDev/atlantis that referenced this issue Jun 21, 2018
Bootstrap is meant for a system that sets itself up. This command is
more like a testing mode so I want to rename it to avoid confusion.

Fixes hootsuite#129 and came out of hootsuite#117.
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

4 participants