gitlab-janitor 1.0.4.94864 → 1.0.4.94868
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/gitlab_janitor/cache_cleaner.rb +4 -4
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 68707afb3c4d00de5e3bbe016591d74a61198786ad3ea5a298a74f3814b061c4
|
4
|
+
data.tar.gz: 07a89ef4b09f63955b0060492f8efa06787abcdc2f8cdecb9ebef1a3d31d564d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f6451ed22578acc8bdc37e9675beccb76c2cb3a0d74df54ceb9f60602cb17379c8caa315033b8acea5dc5df66a8e42807e8f1c092a0a6806243cc1f457a6300d
|
7
|
+
data.tar.gz: 0ce45e45e276e3a32528cf0dc73283b579b26e8d9777913b85ef61fdc07c1e055432c23a7ab660fd8de6ab45d1e51acd2730f0a2e4c960eda5f6d87be1e31595
|
data/Gemfile.lock
CHANGED
@@ -10,8 +10,8 @@ module GitlabJanitor
|
|
10
10
|
def do_clean(keep_size: '10G', remove: false)
|
11
11
|
logger.info 'Removing cache...'
|
12
12
|
if remove
|
13
|
-
prune_builder
|
14
|
-
prune_buildx
|
13
|
+
prune_builder(keep_size)
|
14
|
+
prune_buildx(keep_size)
|
15
15
|
else
|
16
16
|
logger.info 'Skip removal due to dry run'
|
17
17
|
end
|
@@ -19,14 +19,14 @@ module GitlabJanitor
|
|
19
19
|
logger.info(out)
|
20
20
|
end
|
21
21
|
|
22
|
-
def prune_builder
|
22
|
+
def prune_builder(keep_size)
|
23
23
|
out, _status = Open3.capture2e("docker builder prune --keep-storage #{keep_size} -f")
|
24
24
|
logger.info(out)
|
25
25
|
rescue StandardError =>e
|
26
26
|
logger.warn("Unable to clean BUILDER: #{e.inspect}")
|
27
27
|
end
|
28
28
|
|
29
|
-
def prune_buildx
|
29
|
+
def prune_buildx(keep_size)
|
30
30
|
out, _status = Open3.capture2e("docker buildx prune --keep-storage #{keep_size} -f")
|
31
31
|
logger.info(out)
|
32
32
|
rescue StandardError =>e
|