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 exposing revision time alongside revision sha (when using git) #2153

Open
G-Rath opened this issue May 4, 2024 · 3 comments · May be fixed by #2155
Open

Support exposing revision time alongside revision sha (when using git) #2153

G-Rath opened this issue May 4, 2024 · 3 comments · May be fixed by #2155

Comments

@G-Rath
Copy link
Contributor

G-Rath commented May 4, 2024

Important: GitHub issues are for feature requests or bug reports. The Capistrano team recommends you use Stack Overflow for general questions. For more details, please see our contribution policy.


A while ago we had a request from a client that we have a light-weight "versioning" field in the admin panel of their app so they could check if there had been a new deployment - since we use continuous integration and deploy to autoblanced servers we couldn't use the release time as that is effectively arbitrary and not consistent (e.g. if we don't deploy for two weeks and a server is reprovisioned, it'll have a very different release time to the other servers), so to facilitate this we implemented a REVISION_TIME file into our Capistrano deployment which works pretty much exactly how the existing REVISION file does, just with Time™.

We saw this as useful to have in general so landed it in our rails-template (ackama/rails-template#461) and have ported it to a number of our apps without issue.

This is something that feels like a useful and cheap win to be worth having upstreamed into Capistrano itself, especially since most of the code in that PR is just copied from what already exists in Capistrano since (afaik) there's no way to hook in any "closer".

@mattbrictson
Copy link
Member

I agree, this has been a feature I've bolted onto capistrano in the app templates and tools I've created over the years.

I don't have much bandwidth to build this into capistrano right now, but I'd be willing to review a PR, if you are interested in contributing.

@G-Rath
Copy link
Contributor Author

G-Rath commented May 19, 2024

Cool, yup I'm happy to have a crack at it - I'll try to do that over the next week or so

@G-Rath G-Rath linked a pull request May 19, 2024 that will close this issue
3 tasks
@G-Rath
Copy link
Contributor Author

G-Rath commented May 19, 2024

@mattbrictson have opened #2155 which should hopefully be pretty close to done, but either way needs some review for me to continue 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants