Even if I delete the plan, the local directory where the plan was executed still exists.
Is there a restapi that can tell plan to delete the local directory as well? Or is there a good way to delete the local directory?
Hello leegyu86,
Welcome to Atlassian community.
I don't think so any REST API exists which would cleanup these directories, but once you delete a plan Bamboo will automatically cleanup the local working directory on the local agent if any, this process runs few mins after you have deleted a plan, I just tested this now and the folder was delete for me.
2023-12-13 07:39:39,849 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting 1 job(s) marked for deletion
2023-12-13 07:39:39,850 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting SCRIP-TIC-JOB1
2023-12-13 07:39:39,872 INFO [DelayedDeletionThread] [ImmutablePlanCacheServiceImpl] Skipping invalidation, plan is being deleted: SCRIP-TIC
2023-12-13 07:39:39,873 INFO [scheduler_Worker-10] [DeletionServiceHelper] Completed background deletion in 38.66 ms
2023-12-13 07:39:39,880 INFO [DelayedDeletionThread] [DeletionServiceHelper] Deleting 1 stage(s) marked for deletion
2023-12-13 07:39:39,881 INFO [DelayedDeletionThread] [PlanManagerImpl] Removing 1 stage(s) for plan SCRIP-TIC
2023-12-13 07:39:39,889 INFO [DelayedDeletionThread] [ImmutablePlanCacheServiceImpl] Skipping invalidation, plan is being deleted: SCRIP-TIC
2023-12-13 07:39:39,890 INFO [AtlassianEvent::0-BAM::EVENTS:pool-2-thread-59] [DeletionServiceHelper] Completed background deletion in 15.60 ms
The best option would be to delete these directories after each build completion ( if your build does not require files etc from previous build results you can go ahead with this ).
Please follow https://confluence.atlassian.com/bamboo/deleting-a-job-s-current-working-files-1047534685.html to get the exact steps
Regards,
Shashank Kumar
**please don't forget to Accept the answer if your query was answered**
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.