generator: Exit if there's no `/run/ostree`
authorColin Walters <walters@verbum.org>
Fri, 26 Jan 2024 23:10:37 +0000 (18:10 -0500)
committerColin Walters <walters@verbum.org>
Fri, 26 Jan 2024 23:10:37 +0000 (18:10 -0500)
commitb9ce0e89801bbc92d50473d3620b3f41f1dbef9f
tree607b38133aedcadb1acdd091bad11c4d0a0f678c
parentd1d8f4ab40a3557755a867d2367a5510b5e4a265
generator: Exit if there's no `/run/ostree`

Currently if run in a container image under systemd, we will
incorrectly synthesize a `var.mount` unit even if `ostree-prepare-root`
hasn't run.

The comment here said why we didn't do that before, but that's
for the really legacy embedded-only "ostree-prepare-root-static"
path, and even then I'm pretty sure it was wrong because
the generator here only runs in the *real* root, and we should
have `/run/ostree` at that point.
src/libostree/ostree-impl-system-generator.c