mirror of
https://github.com/okxlin/appstore.git
synced 2026-09-30 08:01:10 +00:00
Persist the self-hosted Renovate cache
Restore and save Renovate's public lookup and repository extraction cache with a SHA-pinned GitHub action. Keep private package caching disabled and report cache growth for quota monitoring.
This commit is contained in:
@@ -195,6 +195,23 @@ class RenovateAppVersionTests(unittest.TestCase):
|
||||
self.assertIn("name: Check Docker Hub credentials", workflow)
|
||||
self.assertIn("Configure DOCKERHUB_USERNAME and DOCKERHUB_TOKEN repository secrets", workflow)
|
||||
|
||||
def test_self_hosted_renovate_uses_a_pinned_persistent_cache(self):
|
||||
workflow = (REPO_ROOT / ".github" / "workflows" / "renovate.yml").read_text(
|
||||
encoding="utf-8"
|
||||
)
|
||||
|
||||
self.assertIn(
|
||||
"uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0",
|
||||
workflow,
|
||||
)
|
||||
self.assertIn("path: /tmp/renovate-cache", workflow)
|
||||
self.assertIn("${{ github.run_id }}", workflow)
|
||||
self.assertIn("RENOVATE_CACHE_DIR: /tmp/renovate-cache", workflow)
|
||||
self.assertIn("RENOVATE_REPOSITORY_CACHE: enabled", workflow)
|
||||
self.assertIn("RENOVATE_CACHE_PRIVATE_PACKAGES: 'false'", workflow)
|
||||
self.assertIn("chmod -R a+rwX /tmp/renovate-cache", workflow)
|
||||
self.assertIn("du -sh /tmp/renovate-cache", workflow)
|
||||
|
||||
def test_hosted_and_self_hosted_renovate_have_disjoint_manager_scopes(self):
|
||||
hosted = json.loads((REPO_ROOT / "renovate.json").read_text(encoding="utf-8"))
|
||||
docker = json.loads(
|
||||
|
||||
Reference in New Issue
Block a user