Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Remove dangling docker layers #2017

Merged
merged 1 commit into from
Oct 18, 2022
Merged

ci: Remove dangling docker layers #2017

merged 1 commit into from
Oct 18, 2022

Conversation

FabioLuporini
Copy link
Contributor

No description provided.

@FabioLuporini FabioLuporini added the CI continuous integration label Oct 12, 2022
@codecov
Copy link

codecov bot commented Oct 12, 2022

Codecov Report

Merging #2017 (96fb46a) into master (88bb3c7) will increase coverage by 0.00%.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #2017   +/-   ##
=======================================
  Coverage   87.77%   87.78%           
=======================================
  Files         214      214           
  Lines       36984    36984           
  Branches     5570     5570           
=======================================
+ Hits        32464    32465    +1     
+ Misses       4001     3999    -2     
- Partials      519      520    +1     
Impacted Files Coverage Δ
devito/ir/support/basic.py 92.19% <0.00%> (+0.21%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@@ -78,7 +78,10 @@ jobs:

- name: Build docker image
run: |
docker build . --pull --file docker/Dockerfile.devito --tag devito_img --build-arg base=${{ matrix.base }}
docker build . --rm --pull --file docker/Dockerfile.devito --tag devito_img --build-arg base=${{ matrix.base }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't --rm a run option

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's a build too -- it removes the dangling layers!

docker build . --pull --file docker/Dockerfile.devito --tag devito_img --build-arg base=${{ matrix.base }}
docker build . --rm --pull --file docker/Dockerfile.devito --tag devito_img --build-arg base=${{ matrix.base }}

- name: Remove dangling layers
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So why is it needed again?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

~300 GB of layers on v1003 and counting, which I purged manully for now

if we pushed too much in a good week before docker-build kicks in (which does purge IIRC), we might end up saturating the hard drive

though now that I think about it, that's weird, the base image shouldn't get rebuilt each time... mh

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If there is ~300 GB of layers then there is something else going on probably due to

  • cancelled workflow
  • Dev on the machine

So this may "fix" some of it but it should be safer to have the actual machine have a safety cron job with that

@@ -107,6 +107,9 @@ jobs:
tags: ${{ steps.meta.outputs.tags }}
build-args: base=devitocodes/${{ matrix.base }}

- name: Remove dangling layers
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had the impression this was happening already, ok

@FabioLuporini FabioLuporini merged commit dcdf021 into master Oct 18, 2022
@FabioLuporini FabioLuporini deleted the tweak-docker branch October 18, 2022 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI continuous integration
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants