How can I access the currently deployed Revision in a deployment callback?
Say you want to notify Hoptoad of a successful deployment. It requires the currently deployed revision to be useful. The information is there, it's just not exactly available in the way you're used to from e.g. Capistrano. The revision is stored on an attribute of the deploy resource called scm_provider. To access the current revision, you can do the following in your callback files:
current_revision = scm_provider.revision_slug
This works the same with Subversion and Git, returning the according revision number or SHA1 respectively.
-
FAQ
-
Applications
-
Basics
-
Custom Instance Setup
-
Deployment
-
Security
-
Auto Healing
-
Tutorials
- Tutorial: Customizing your Scalarium Cloud using Chef
- Customizing your Scalarium Cloud using Chef: The Scalarium Lifecycle System
- Customizing your Scalarium Cloud using Chef: Cooking with Chef
- Customizing your Scalarium Cloud using Chef: Writing a Cookbook to set up Redis
- Customizing your Scalarium Cloud using Chef: Configuring Custom Cookbooks
- View all (4 more)
-
Load Based Auto Scaling
-
Time Based Auto Scaling
-
API