Deployment Version

Hello! I’m wondering if there is any way to get the deployment version into the env of the vm, similar to what we see here:


I would love to have that 35 value. Even if I could set it via fly deploy -e would be fine.


Currently, we add these runtime environment variables (which unfortunately doesn’t include the version number). You could always set the version number in an environment variable in fly.toml though. I’m curious as to the use case for having it automatically set though.

Thanks for the link! I was integrating into Datadog and thought it would be nice if my deployment versions matched between fly and datadog. I ended up deploying with the current date and time as the version. Thanks!

1 Like

Just a note, you can get it from inside the machine:

curl --silent 
     --unix-socket /.fly/api "http://localhost/v1/apps/$FLY_APP_NAME/machines/$FLY_MACHINE_ID/metadata" 
     | jq .fly_release_version

But it would be great to have it as an env var, just like Heroku’s HEROKU_RELEASE_VERSION.


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.