runatlantis / atlantis

Terraform Pull Request Automation
https://www.runatlantis.io
Other
7.87k stars 1.06k forks source link

Autoplan when a workspace is added #1025

Open glenwinters opened 4 years ago

glenwinters commented 4 years ago

I'm using multiple workspaces as described here in the docs and noticed that if I only add a new workspace in a PR, Atlantis doesn't plan.

That behavior makes sense given the workflow in the Autoplanning docs that say "Atlantis will attempt to run terraform plan in the directories it thinks hold modified Terraform projects". In this case, no terraform files were modified, only atlantis.yml.

Has someone come up with a config or custom workflow that will specifically autoplan a workspace that was added in the PR?

My current workaround is to modify a comment or add whitespace in one of the terraform files.

krzysztof-magosa commented 4 years ago

Instead of editing files, you can do atlantis plan -d directory/in/repo.