Deploy tracking with Ruby on Rails and Capistrano

Like every commit has a reason and purpose, I think every deployment has a purpose and reason. The source code component has a comment. But the deployment does not have.

How to automatically record the cause and goal for each deployment?

I need to save a record:

  • Who deployed where and at what time.
  • Why deploy? Error correction? Feature update? Extreme fix not on iteration plan?
  • Which git or svn ref was used?

Has anyone felt the need for such a system? How do you feel about my approach? How can I achieve my goal? I am currently using Capistrano for deployment.


Added generosity. I would like to hear more stories from different developers who do "continuous deployment".


I found two services that deploy tracking:

+4
source share
5 answers

Webistrano - https://github.com/peritor/webistrano/wiki is a web interface for capistrano that also keeps track of who and what has been deployed, so it can be worth exploring.

+3
source

My current project uses a modified version of apinsein git -deployment recipe , which (when you indicate that you want to deploy) marks the current HEAD with a Git tag (which gives you all the benefits of normal Git).

+1
source

I created a web service for this exact problem, http://deploytracking.com , it connects to capistrano and records the time, user, branch, ref, environment and repos that were involved in the deployment.

+1
source

Strano - Github has supported the Capistrano deployment management interface.

Regarding continuous deployment, I also sent a request for there, which Deploys automatic deployments for GitHub projects , because now it just launches the deployment task when someone clicks on the main branch.

0
source

I do not know how relevant this is, but I would like to propose another solution. I am creating a new deployment tool that does exactly what you are looking for. I'm not going to spam my stuff here, but since I'm building something that can help you ...

Anyway, look here https://alessiosantocs.imtqy.com/Captain . I collect feedback, so if you have any requests, let me know.

Update

As I said, I give an explanation :)

I also felt this need. I work in a digital startup, and we constantly post material 5 days a week on another Ruby on Rails application with Capistrano.

We noticed that for each deployment we had to do a few things:

  • Keep track of which push and commit requests are coming out online at that moment.
  • Give some name to the deployment so that we can recognize it.
  • Notify our team members so that everyone can be on the same page (without asking us about deployment news).
  • Keep track of each deployment for future errors and errors that we might find at a particular point in time (which often happened)

Therefore, for this reason, we began to develop this custom solution, which would integrate with Capistrano and our SCM (bitbucket) and track all the changes that we made to our main branch. This is what he is doing right now.

We are currently tracking the deployment environment, repo source, deployment branch, and revision. We mainly manage traction requests because we found that traction requests, better than committing, solved the organizational problem in our team (it was difficult to approve another team member code without a rigid system such as PR)

I would like to talk more about the captain and our personal HR strategy with you guys, if you want.

Thanks @thirumalaimurugan for asking for clarification!

Update 2

We also tried git tags. It was good and fun at the beginning, but we could not deal with them very well.

A tag is basically a bookmark for a specific revision. Therefore, we are talking about commits. The tag does not track pull requests. It was a mess for us.

I do not think that they are bad in what you are trying to achieve, but I think that there should be some other solutions that could correspond to your (and our) problem.

0
source

Source: https://habr.com/ru/post/1310529/


All Articles