mirror of
https://gitlab.com/futo-org/fcast.git
synced 2025-07-16 10:58:45 +00:00
Fix artifact cleanup
This commit is contained in:
parent
736b0c9fdc
commit
977ac3328b
1 changed files with 3 additions and 2 deletions
|
@ -1,3 +1,4 @@
|
||||||
|
import glob
|
||||||
import os
|
import os
|
||||||
import hashlib
|
import hashlib
|
||||||
import boto3
|
import boto3
|
||||||
|
@ -63,8 +64,8 @@ def copy_artifacts_to_local_cache():
|
||||||
shutil.copytree('/artifacts', dst, dirs_exist_ok=True, ignore=shutil.ignore_patterns('*.w*'))
|
shutil.copytree('/artifacts', dst, dirs_exist_ok=True, ignore=shutil.ignore_patterns('*.w*'))
|
||||||
|
|
||||||
# Clean up old job artifacts
|
# Clean up old job artifacts
|
||||||
shutil.rmtree('/artifacts')
|
for file in glob.glob(os.path.join('/artifacts', '*')):
|
||||||
os.makedirs('/artifacts', exist_ok=True)
|
os.remove(file)
|
||||||
return version
|
return version
|
||||||
|
|
||||||
def sync_local_cache():
|
def sync_local_cache():
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue