File tree 2 files changed +9
-5
lines changed
2 files changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -186,11 +186,12 @@ def _before_squashing(self):
186
186
try :
187
187
number_of_layers = int (self .from_layer )
188
188
189
- self .log .debug ("We detected number of layers as the argument to squash" )
189
+ self .log .debug (
190
+ f"We detected number of layers ({ number_of_layers } ) as the argument to squash"
191
+ )
190
192
except ValueError :
191
- self .log .debug ("We detected layer as the argument to squash" )
192
-
193
193
squash_id = self ._squash_id (self .from_layer )
194
+ self .log .debug (f"We detected layer ({ squash_id } ) as the argument to squash" )
194
195
195
196
if not squash_id :
196
197
raise SquashError (
Original file line number Diff line number Diff line change @@ -143,8 +143,11 @@ def squash(self, image: Image):
143
143
# Load squashed image into Docker
144
144
image .load_squashed_image ()
145
145
146
- # Clean up all temporary files
147
- image .cleanup ()
146
+ # If development mode is not enabled, make sure we clean up the
147
+ # temporary directory
148
+ if not self .development :
149
+ # Clean up all temporary files
150
+ image .cleanup ()
148
151
149
152
# Remove the source image - this is the only possible way
150
153
# to remove orphaned layers from Docker daemon at the build time.
You can’t perform that action at this time.
0 commit comments