sonic-buildimage/.azure-pipelines/cleanup.yml
liushilongbuaa 14c79ee9f0 [CI] Fix pipeline template artifacts struct bug and cleanup bug
Signed-off-by: liushilongbuaa <shilongliu@microsoft.com>
2021-05-12 15:25:36 +08:00

15 lines
441 B
YAML

steps:
- script: |
if sudo [ -f /var/run/march/docker.pid ] ; then
pid=`sudo cat /var/run/march/docker.pid` ; sudo kill $pid
fi
sudo rm -f /var/run/march/docker.pid
sudo rm -rf /data/march/docker
# clean native docker build
if sudo [ -f dockerfs/var/run/docker.pid ] ; then
pid=`sudo cat dockerfs/var/run/docker.pid` ; sudo kill $pid
fi
sudo rm -rf $(ls -A1)
displayName: "Clean Workspace"