runatlantis / atlantis

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

Reaction emojis when running atlantis workflows #1084

Open nitrocode opened 4 years ago

nitrocode commented 4 years ago

I've been using the cloudposse chatops commands recently. When I run /readme-rebuild or similar, the chatops github action will first update my comment with 👀 to show that it has been seen, 🚀 when it has been dispatched, and finally 🎉 (or similar) when it completes.

Example: https://github.com/cloudposse/terraform-aws-alb-ingress/pull/26#issuecomment-645371322 Action code: https://github.com/cloudposse/actions/tree/master/github/slash-command-dispatch

I'd like to see something similar with atlantis chatops. Thank you!

Edit:

We can add the 👀 right before this

https://github.com/runatlantis/atlantis/blob/d1d1539ced062ccb8dc2a0368b4e4c802b6799b6/server/controllers/events/events_controller.go#L92-L93

We can add 🚀 right before this

https://github.com/runatlantis/atlantis/blob/d1d1539ced062ccb8dc2a0368b4e4c802b6799b6/server/controllers/events/events_controller.go#L303-L305

https://github.com/runatlantis/atlantis/blob/d1d1539ced062ccb8dc2a0368b4e4c802b6799b6/server/events/command_runner.go#L276

We can add an error emoji ❌ if an error is thrown (probably other places where we need to add an error)

https://github.com/runatlantis/atlantis/blob/d1d1539ced062ccb8dc2a0368b4e4c802b6799b6/server/events/command_runner.go#L276-L282

And if no error, we can add 🎉

Then need to set it up for gitlab, bitbucket, and any other VCS. Starting with github would be very nice!

osterman commented 4 years ago

Dependabot is another great example.

https://github.com/cloudposse/geodesic/pull/551#issuecomment-584390508

lkysow commented 4 years ago

That would be super cool!

ghostsquad commented 4 years ago

yes please - updating comments instead of posting new comments for plans would also be a welcome change. It makes the conversation cleaner.

osterman commented 4 years ago

updating comments instead of posting new comments for plans would also be a welcome change

yea, probably not a bad thing either, but should be a new feature request if not one already. The history is still preserved by github, and the noise would be so much less.

image

ghostsquad commented 4 years ago

what's with the screenshot?

Ya, I can make a new feature request.

ghostsquad commented 4 years ago

Created #1192

nitrocode commented 2 years ago

I thought about this issue again today since github had issues with its webhooks. An additional benefit of this feature is that when github has issues sending out its web hooks in the future, you would know immediately github is having issues if you ran atlantis plan and a new emoji wasn't immediately added to your comment.

Ref: https://www.githubstatus.com/incidents/smn1qtqvbsb6

marcusramberg commented 2 years ago

I'll try to implement this as a PR.

nitrocode commented 1 year ago

This ticket is only partially completed.

I think we have the ability to set an emoji only when Atlantis kicks off but no emoji when Atlantis is running or when it errors out