We currently have a build process in Bamboo that checks out our source code from the master branch in stash on commit and then builds a debian DEB package ready for deployment. Our deployment proces then pushes this DEB package to AWS S3 ready for installation on our verious servers.
The problem I have is that the context files, which is required when building a DEB package, requires a version number for the DEB file. This is used when installing a DEB package to determine if the DEB package has already been installed. The problem is that the release version number, as determined by the release version section of the deployment plan is generated too late in the process.
I would like to use the release version number created by the deployment process to stamp the version in the context file, but the DEB package is built at this point in the process. Again, I dont want to move the building of the package into the deployment process because we have different target environments in the deployment process, and because building the DEB package during deployment seems like the wrong place to do this.
Does anyone have any suggestions? Has anyone else used Bamboo to build and deploy DEB packages? How did you solve the context file version problem?