From 533c5bee41355fdca2048a1757e7668472631843 Mon Sep 17 00:00:00 2001 From: FosterStack Admin <317177128+fosterstack-admin@users.noreply.github.com> Date: Thu, 8 Oct 2026 20:16:48 -0400 Subject: [PATCH 1/7] Page: migrate from Build Cache Node, Gradle and Maven setup --- migrate-build-cache-node/index.html | 183 ++++++++++++++++++++++++++++ sitemap.xml | 4 + 2 files changed, 187 insertions(+) create mode 100644 migrate-build-cache-node/index.html diff --git a/migrate-build-cache-node/index.html b/migrate-build-cache-node/index.html new file mode 100644 index 0000000..8c33bd1 --- /dev/null +++ b/migrate-build-cache-node/index.html @@ -0,0 +1,183 @@ + + + + + +Migrate from Build Cache Node: Gradle and Maven setup + + + + + + + + +
+ +
Infrastructure worth keeping — and kept patched.
+
+
+

Migrate from Build Cache Node: Gradle and Maven setup

+

Stand up a replacement cache, change one URL, check that it works. About 30 minutes for Gradle. There is no data to move.

+ +

Before you start

+

A build cache holds copies of things your builds can always rebuild, so there is nothing to export from the old node. Your first build on the new server just fills it. If you have not read why the node is going away, see Build Cache Node end of life.

+ +

Step 1: Run the new cache server

+
docker run -d -p 8080:8080 -v fscache-data:/home/nonroot ghcr.io/fosterstack/cache:latest
+

For anything beyond a first look, pin a specific version instead of latest. Put the server behind HTTPS before real builds use it. Other ways to run it (bare binary with systemd, Kubernetes, offline networks) are in the install guide.

+

If the server can be reached by anyone you do not trust, turn on Basic Auth. Anyone who can write to the cache can change what your later builds use.

+ +

Step 2: Gradle build cache setup

+

Turn the cache on, in gradle.properties:

+
org.gradle.caching=true
+

Then point Gradle at the new server in settings.gradle.kts. If you used the old node, you only change the URL:

+
// FosterStack Cache — remote Gradle build cache.
+// https://github.com/fosterstack/cache
+buildCache {
+    remote<HttpBuildCache> {
+        url = uri("https://cache.example.com/")
+        isPush = true
+        credentials {
+            username = "gradle"
+            password = System.getenv("FSCACHE_PASSWORD")
+        }
+    }
+}
+

Or in settings.gradle (Groovy):

+
// FosterStack Cache — remote Gradle build cache.
+// https://github.com/fosterstack/cache
+buildCache {
+    remote(HttpBuildCache) {
+        url = 'https://cache.example.com/'
+        push = true
+        credentials {
+            username = 'gradle'
+            password = System.getenv('FSCACHE_PASSWORD')
+        }
+    }
+}
+

Keep the comment lines: a cache block that points at an unfamiliar host looks like data theft to a reviewer without them. Keep the trailing slash on the URL. Leave the credentials block in even if the server has no password yet; it is ignored then.

+ +

Step 3: Maven build cache setup

+

Maven uses Apache's Build Cache Extension. FosterStack Cache implements the server side of it. The server part is built; its acceptance testing is still in progress.

+

Add the extension in .mvn/extensions.xml (check Maven Central for the current version):

+
<extensions>
+  <extension>
+    <groupId>org.apache.maven.extensions</groupId>
+    <artifactId>maven-build-cache-extension</artifactId>
+    <version>1.2.3</version>
+  </extension>
+</extensions>
+

Point it at the server in .mvn/maven-build-cache-config.xml:

+
<?xml version="1.0" encoding="UTF-8"?>
+<cache xmlns="http://maven.apache.org/BUILD-CACHE-CONFIG/1.2.0">
+  <configuration>
+    <enabled>true</enabled>
+  </configuration>
+  <!-- FosterStack Cache — remote Maven build cache.
+       https://github.com/fosterstack/cache -->
+  <remote enabled="true" id="fosterstack-cache">
+    <url>https://cache.example.com/</url>
+  </remote>
+</cache>
+

If the server uses Basic Auth, add a matching <server> with the same id (fosterstack-cache) in ~/.m2/settings.xml. Then run mvn install.

+

The extension itself is Apache's project. If your hit rate looks low, start with the extension's own configuration guide.

+ +

Step 4: Check that it works

+

For Gradle, run the build twice:

+
./gradlew build --build-cache
+

On the second run, look for FROM-CACHE next to tasks. Gradle also has a local cache that gives hits even when the remote is broken, so to test the remote itself, clear the local one and run with -i:

+
rm -rf ~/.gradle/caches/build-cache-1
+./gradlew --stop
+./gradlew build --build-cache -i
+

On the server, the hit and miss counters should move:

+
curl -s https://cache.example.com/metrics | grep -E 'fscache_cache_(hits|misses)_total'
+

For Maven, build twice from a clean checkout and look for cache hits in the log for unchanged modules.

+ +

Step 5: Retire the old node

+

Once builds hit the new server, stop the old Build Cache Node container.

+ +

What you give up

+

The old node had a small web page with a purge button. FosterStack Cache has no settings page. You set it with flags and environment variables, and a read-only status page shows size and hit counts. To empty the cache, remove its volume and start again.

+ +

Full details: Gradle docs, Maven docs, migration guide on GitHub.

+
+ FosterStack Cache on GitHub + FosterStack home +
+
+ + + diff --git a/sitemap.xml b/sitemap.xml index 8c1e470..1f932e9 100644 --- a/sitemap.xml +++ b/sitemap.xml @@ -16,4 +16,8 @@ weekly 1.0 + + https://fosterstack.com/migrate-build-cache-node/ + 2026-10-08 + From 8a84ddc9513b89001abc16fc868040164fdbfc92 Mon Sep 17 00:00:00 2001 From: FosterStack Admin <317177128+fosterstack-admin@users.noreply.github.com> Date: Thu, 8 Oct 2026 20:18:16 -0400 Subject: [PATCH 2/7] Migrate page: localhost-only docker command, direct doc links --- migrate-build-cache-node/index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/migrate-build-cache-node/index.html b/migrate-build-cache-node/index.html index 8c33bd1..dfd3d53 100644 --- a/migrate-build-cache-node/index.html +++ b/migrate-build-cache-node/index.html @@ -85,8 +85,8 @@

Before you start

A build cache holds copies of things your builds can always rebuild, so there is nothing to export from the old node. Your first build on the new server just fills it. If you have not read why the node is going away, see Build Cache Node end of life.

Step 1: Run the new cache server

-
docker run -d -p 8080:8080 -v fscache-data:/home/nonroot ghcr.io/fosterstack/cache:latest
-

For anything beyond a first look, pin a specific version instead of latest. Put the server behind HTTPS before real builds use it. Other ways to run it (bare binary with systemd, Kubernetes, offline networks) are in the install guide.

+
docker run -d -p 127.0.0.1:8080:8080 -v fscache-data:/home/nonroot ghcr.io/fosterstack/cache:latest
+

For anything beyond a first look, pin a specific version instead of latest. This command listens on this machine only. For other machines to use it, put an HTTPS proxy in front. Other ways to run it: bare binary with systemd, Kubernetes, or a disconnected network.

If the server can be reached by anyone you do not trust, turn on Basic Auth. Anyone who can write to the cache can change what your later builds use.

Step 2: Gradle build cache setup

From 5afd95a663b818889f732c37f869dc0ec3540e81 Mon Sep 17 00:00:00 2001 From: FosterStack Admin <317177128+fosterstack-admin@users.noreply.github.com> Date: Thu, 8 Oct 2026 20:35:37 -0400 Subject: [PATCH 3/7] Owner cold-read edit: Maven stated without the in-progress hedge --- migrate-build-cache-node/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migrate-build-cache-node/index.html b/migrate-build-cache-node/index.html index dfd3d53..28042fd 100644 --- a/migrate-build-cache-node/index.html +++ b/migrate-build-cache-node/index.html @@ -121,7 +121,7 @@

Step 2: Gradle build cache setup

Keep the comment lines: a cache block that points at an unfamiliar host looks like data theft to a reviewer without them. Keep the trailing slash on the URL. Leave the credentials block in even if the server has no password yet; it is ignored then.

Step 3: Maven build cache setup

-

Maven uses Apache's Build Cache Extension. FosterStack Cache implements the server side of it. The server part is built; its acceptance testing is still in progress.

+

Maven uses Apache's Build Cache Extension. FosterStack Cache implements the server side of it.

Add the extension in .mvn/extensions.xml (check Maven Central for the current version):

<extensions>
   <extension>

From e59b25c5987fc51b2c30a5a6e80313dc82b46b3a Mon Sep 17 00:00:00 2001
From: FosterStack Admin <317177128+fosterstack-admin@users.noreply.github.com>
Date: Thu, 8 Oct 2026 20:38:04 -0400
Subject: [PATCH 4/7] Migration guide: Security is the difference

---
 migrate-build-cache-node/index.html | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/migrate-build-cache-node/index.html b/migrate-build-cache-node/index.html
index 28042fd..19e4475 100644
--- a/migrate-build-cache-node/index.html
+++ b/migrate-build-cache-node/index.html
@@ -159,6 +159,22 @@ 

Step 4: Check that it works

Step 5: Retire the old node

Once builds hit the new server, stop the old Build Cache Node container.

+

Security is the difference

+

Security is what sets this product apart. Everything below ships in the current release, and you can check each item yourself.

+ +

What you give up

The old node had a small web page with a purge button. FosterStack Cache has no settings page. You set it with flags and environment variables, and a read-only status page shows size and hit counts. To empty the cache, remove its volume and start again.

From ae77288509754ba6c7787780ca2937ea377f35b1 Mon Sep 17 00:00:00 2001 From: FosterStack Admin <317177128+fosterstack-admin@users.noreply.github.com> Date: Thu, 8 Oct 2026 20:39:16 -0400 Subject: [PATCH 5/7] Security section: Signed and verifiable / Supply chain groups, v0.2.1 facts only --- migrate-build-cache-node/index.html | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/migrate-build-cache-node/index.html b/migrate-build-cache-node/index.html index 19e4475..2d169b5 100644 --- a/migrate-build-cache-node/index.html +++ b/migrate-build-cache-node/index.html @@ -161,14 +161,23 @@

Step 5: Retire the old node

Security is the difference

Security is what sets this product apart. Everything below ships in the current release, and you can check each item yourself.

+

Signed and verifiable

+

Supply chain

+ +

Small, quiet and patched

+

Point it at the server in .mvn/maven-build-cache-config.xml:

<?xml version="1.0" encoding="UTF-8"?>
-<cache xmlns="http://maven.apache.org/BUILD-CACHE-CONFIG/1.2.0">
+<cache xmlns="http://maven.apache.org/BUILD-CACHE-CONFIG/1.2.0"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://maven.apache.org/BUILD-CACHE-CONFIG/1.2.0 https://maven.apache.org/xsd/build-cache-config-1.2.0.xsd">
   <configuration>
     <enabled>true</enabled>
+    <!-- FosterStack Cache — remote Maven build cache.
+         https://github.com/fosterstack/cache -->
+    <remote enabled="true" saveToRemote="true" id="fosterstack-cache">
+      <url>https://cache.example.com/</url>
+    </remote>
   </configuration>
-  <!-- FosterStack Cache — remote Maven build cache.
-       https://github.com/fosterstack/cache -->
-  <remote enabled="true" id="fosterstack-cache">
-    <url>https://cache.example.com/</url>
-  </remote>
 </cache>
-

If the server uses Basic Auth, add a matching <server> with the same id (fosterstack-cache) in ~/.m2/settings.xml. Then run mvn install.

+

The remote element must be inside configuration, and saveToRemote="true" is what makes the machine upload; without it the server stays empty. If the server uses Basic Auth, add a matching <server> with the same id (fosterstack-cache) in ~/.m2/settings.xml. Then run mvn install.

The extension itself is Apache's project. If your hit rate looks low, start with the extension's own configuration guide.

Step 4: Check that it works