1

We have a teamcity build server and deploy to Windows server using the octopus auto deploy.

The local builds of the program are good, but the deployed exe does not reflect the changes. I can even see the committed code on BitBucket.

I used DotPeek to check the exe for the updated code. I do not want to manually deploy it.

We used to have this problem in the past. It used to be fixed by re-running the deployment. I have done those deployments 10 times today and still cannot get my code changed.

The desired behavior is to deploy the committed code successfully. Has anyone encountered something similar?

  • Questions seeking debugging help ("**why isn't this code working?**") must include the desired behavior, a specific problem or error and the shortest code necessary to reproduce it **in the question itself**. Questions without a **clear problem statement** are not useful to other readers. See: [How to create a Minimal, Complete, and Verifiable example](http://stackoverflow.com/help/mcve). – CoderDennis Oct 25 '16 at 21:01
  • I added the desired behavior. Even the documentation/knowledge base doesn't support any thing like this. This had happened to us as a one off incident in the past. Now I cannot deploy any committed code on the server. – Swapnil Tamse Oct 27 '16 at 21:32
  • Are you deploying a NuGet? – gvee Nov 17 '16 at 09:10

2 Answers2

0

When you create octopus releases automatically from build process it will automatically pick "latest" code packages from nuget feed. Latest here means version number not date.

For example at some point you could have pushed a package with version 1.1.222 to octopus, then you changed versioning and now have packages with versions 1.0.1.223, 1.0.1.224. In such a case Octopus will keep selecting 1.1.222 as latest because it's version number is bigger.

So. 1. Make sure your build process actually increments package versions. 1.1 Check your package feed (of it is built-in octopus feed go to Library page in Octopus) an make sure that newest packages have newer version. 2. Check what version of package was picked by octopus by going to Project> Releases > (release number) 3. Add steps in your build process to version .exe/.DLL files too, so you can check version without disassembling (only opening file properties)

Hope this helps.

Community
  • 1
  • 1
Eduard
  • 897
  • 5
  • 11
0

You can force fro build Octopus to use specific version for your release and deployment

octo create-release  --releaseNumber=VALUE --deployto=VALUE

this will deploy to your target environment using specific releaseNumber even though version could be will lower number

Steven J
  • 316
  • 2
  • 14