diff options
author | Dan Nicholson <dbn@endlessos.org> | 2021-04-30 10:14:52 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-30 10:14:52 -0600 |
commit | af723f9a2a7baf28ccb4a037b2c97737621fba56 (patch) | |
tree | 26136076b6c44d633cb9d46c449a4a45095abf58 | |
parent | 89481ca4be2a5c52f7b3d4ff4a32b14cd6e982ab (diff) | |
parent | 788e171b7cf3ff87b2a73cd4734644eebb9db989 (diff) | |
download | ostree-master.tar.gz |
Merge pull request #2355 from jlebon/pr/etc-merge-moar-docsmaster
docs: Add more details about 3-way merge
-rw-r--r-- | docs/atomic-upgrades.md | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/docs/atomic-upgrades.md b/docs/atomic-upgrades.md index f4b31aca..3270ff6e 100644 --- a/docs/atomic-upgrades.md +++ b/docs/atomic-upgrades.md @@ -69,10 +69,26 @@ given commit is deployed more than once, it will be incremented. This is supported because the previous deployment may have configuration in `/etc` that we do not want to use or overwrite. -Now that we have a deployment directory, a 3-way merge is -performed between the (by default) currently booted deployment's -`/etc`, its default -configuration, and the new deployment (based on its `/usr/etc`). +Now that we have a deployment directory, a 3-way merge is performed +between the (by default) currently booted deployment's `/etc`, its +default configuration, and the new deployment (based on its `/usr/etc`). + +How it works is: +- Files in the currently booted deployment's `/etc` which were modified + from the default `/usr/etc` (of the same deployment) are retained. +- Files in the currently booted deployment's `/etc` which were not + modified from the default `/usr/etc` (of the same deployment) are + upgraded to the new defaults from the new deployment's `/etc/etc`. + +Roughly, this means that as soon as you modify or add a file in `/etc`, +this file will be propagated forever as is (though there is a +corner-case, where if your modification eventually exactly matches a +future default file, then the file will go back to following future +default updates from that point on). + +You can use `ostree admin config-diff` to see the differences between +your booted deployment's `/etc` and the OSTree defaults. A command like +`diff {/usr,}/etc` will additional print line-level differences. ## Atomically swapping boot configuration |