Can I inherit the tag from a previous build when I promote a build?

I have a promote step in my pipeline, and I would like to inherit the tag of the build that I am promoting in order to tag a dockerfile I am building in the pipeline properly. Is there a way to do this?

Hello @newtorob,

Could you please provide more details regarding the use case and the issue that you are facing, so that we can suggest accordingly.

Harness support

Yes, so when my developers tag a build e.g 1.04 in the pipeline and it triggers one of our builds to our QA instance, I was wondering if there is a way to persist that tag if we promote that build to production. When we tag it for QA we can keep that tag and use it to tag our images that get pushed to GCR. Is there a way to make sure I can do the same thing when I promote that tagged build to production?

Reading the documentation it looks like the promotion generates a new build number but I didn’t see a way to use DRONE_TAG when doing a promotion.