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

Enhancements to cache + print configs and environment #15

Merged
merged 5 commits into from
Apr 24, 2022
Merged

Conversation

mkurz
Copy link
Member

@mkurz mkurz commented Apr 24, 2022

No description provided.

@@ -20,6 +20,7 @@ jobs:
fetch-depth: 0

- name: Coursier Cache
id: coursier-cache
Copy link
Member Author

Choose a reason for hiding this comment

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

We need an id once coursier/cache-action#296 is merged.

find $HOME/Library/Caches/Coursier/v1 -name "ivydata-*.properties" -delete || true
find $HOME/.ivy2/cache -name "ivydata-*.properties" -delete || true
find $HOME/.cache/coursier/v1 -name "ivydata-*.properties" -delete || true
find $HOME/.sbt -name "*.lock" -delete || true
Copy link
Member Author

Choose a reason for hiding this comment

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

Removing those files is recommended, see https://www.scala-sbt.org/1.x/docs/GitHub-Actions-with-sbt.html#Caching
Also we had this in our travis conf as well: https://github.com/playframework/playframework/blob/599f9a16ef4a623721431585ee731501df4e667d/.travis.yml#L88-L90
(I kept the macOS line, just in case we ever run this workflow on it. Who knows.)

ls -alFhR ~/.ivy2 | grep play | grep jar || true
echo "ls -alFhR ~/.cache/coursier | grep play | grep jar"
ls -alFhR ~/.cache/coursier | grep play | grep jar || true

Copy link
Member Author

Choose a reason for hiding this comment

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

@@ -0,0 +1,26 @@
name: Trigger cache invalidation
Copy link
Member Author

@mkurz mkurz Apr 24, 2022

Choose a reason for hiding this comment

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

See explanation in playframework/playframework#11247.
Also some more notes about caching here: playframework/playframework#11142
Right now it seems the cache gets cleared every day at around 11:10 PM (when the used cache exceeds the 10 GB limit)

@mkurz
Copy link
Member Author

mkurz commented Apr 24, 2022

I did test this with playframework/playframework#11142.
Also the clear cache workaround does work (tested the last two nights with the play repo and with a test repo: https://github.com/mkurz/release-drafter-test/commits/master)

@mkurz
Copy link
Member Author

mkurz commented Apr 24, 2022

I will merge this. If someone wants to change something, please let me know or just open a pull request.

@mkurz mkurz merged commit 425128b into main Apr 24, 2022
@mkurz mkurz deleted the clean-cache branch April 24, 2022 09:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant