I have come across a slight problem in the setup that I have developed and was hoping for some advice on my release procedure.
As it stands, I use my development box to build with jenkins / maven. To build my application I created a delivery pipeline which looks as follows
Every time my application is built, it uses the name appname-1.0.war and I have seen that using the maven release plugin ( Maven versioning best practices ) we can get maven to increment the build number.
My issue however is this;
My prod build in the pipeline essentially builds the application with prod profiles on dev, when built, scp's the file to prod and then deploys to the relevant directory.
1) This therefore overwrites an existing application with the same name
2) If i use maven release plugin the filename will always be changing, so how can I scp the correct file if i don't know its name in advance?
Hopefully I have given enough details of the issue I face as I really would like a mechanism that allows me on production to roll back to a previous release as currently this is not possible.
Thanks