We have many projects with CaC enabled but one in particular keeps getting:
Octopus Server returned an error: failed to make directory ‘E:/Octopus/Git/VQMMNQ722W5Z6ZRBEVPMREEZKPPPXLZN/root/worktrees/c3D7HRZ3NBDEAEI67JJTA6W5TRAQE2QSK’: directory exists
If i remove the folder and re-run it just recreates it.
Have tried creating a new branch, changing the default branch, creating a new release and cleared the git cache from the UI but still there’s a problem.
That’s an unusual error and not one that I’ve seen before.
When you create a new release, does it return the same directory path or a new one?
Would you send across the Task Logs (preferably for a successfully completing deployment) and a Deployment Process for the Project?
A colleague and I have been looking at this issue and have a theory or two. Can you look at your folder permissions at the worktrees level and the newly created folder level. I wonder if the user your running Octopus as, doesn’t have permissions on the newly created folder.
One thing that I have seen once or twice, depending on the how the folders are created, is that one folder will be created by a user and has ‘take ownership’ permission, but the owner permission will mean that a different user (in this case, possibly the user account that runs the octopus service) will not have modify access.
Have a look at what permissions exist on those folders and if there could be something amiss.
You can upload the files I mentioned earlier, securely via this link