I'm trying to solve an issue with deploying to multiple servers in a server role. The issue is represented under the following circumstances:
Build Plan (pseudo-code):
1) On Server: Buildmaster, execute command, git clone $repo
2) Build Artifact
3) Deploy Artifact
Deploy to: web12 (web1, web2 servers);
What ends up happening is that Buildmaster is able to successfully execute the above plan from start to finish for web1, but upon attempting the git clone again for web2, the job fails since git clone requires an empty directory.
This issue emerges since build plans linked in pipelines are implicitly inside of a: for server in $pipeline_stage block, and the git clone is then executed twice in the same temporary directory.
- can buildmaster use a different temporary directory for each server?
or 2) can buildmaster clear the temporary directory for each successful server build
or 3) can I ask buildmaster to execute a build action outside of the server block loop
Any insight into this issue would be appreciated!