Repository: systemd/mkosi

Issue:
bwrap --tmpfs option disrupts --workspace-dir=/tmp/foo  
I encountered this with `--workspace-dir`, but I expect other options would be affected too.

```console
$ bin/mkosi -C /usr/lib/mkosi-initrd/ --workspace-dir=/tmp/aaa --finalize-script=/usr/lib/mkosi-initrd/mkosi.finalize --image-version=6.5.0-0.rc7.20230821gitf7757129e3de.50.fc39.x86_64 --environment=KERNEL_VERSION=6.5.0-0.rc7.20230821gitf7757129e3de.50.fc39.x86_64 -O /tmp/asdf/ -o initrd
‣ Removing output files…
‣ Building default image
‣  Installing Fedora
```
`‣ + bwrap --dev-bind / / --tmpfs /tmp --bind /usr/lib/mkosi-initrd /usr/lib/mkosi-initrd --chdir /usr/lib/mkosi-initrd --unshare-pid --unshare-ipc --unshare-cgroup --die-with-parent --proc /proc --dev /dev --ro-bind /sys /sys --setenv SYSTEMD_OFFLINE 1 --setenv PATH /tmp/aaa/.mkosi-tmpekerldi6/mkosi-scripts218x44qg:/home/zbyszek/bin:/home/zbyszek/.local/bin:/usr/share/Modules/bin:/usr/lib64/ccache:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin sh -c 'chmod 1777 /tmp /dev/shm && exec $0 "$@"' strace -y -o /tmp/log /usr/bin/dnf5 --assumeyes --config=/tmp/aaa/.mkosi-tmpekerldi6/pkgmngr/etc/dnf/dnf.conf --best --releasever=39 --installroot=/tmp/aaa/.mkosi-tmpekerldi6/root --setopt=keepcache=1 '--setopt=cachedir=/tmp/aaa/.mkosi-tmpekerldi6/cache/fedora~39' --setopt=reposdir=/tmp/aaa/.mkosi-tmpekerldi6/pkgmngr/etc/yum.repos.d --setopt=varsdir=/tmp/aaa/.mkosi-tmpekerldi6/pkgmngr/etc/dnf/vars --setopt=persistdir=/tmp/aaa/.mkosi-tmpekerldi6/pkgmngr/var/lib/dnf --setopt=check_config_file_age=0 '--disableplugin=*' --enableplugin=builddep --no-docs install filesystem`
`Configuration file "/tmp/aaa/.mkosi-tmpj9eoi734/pkgmngr/etc/dnf/dnf.conf" not found`
`‣ "/usr/bin/dnf5 --assumeyes --config=/tmp/aaa/.mkosi-tmpj9eoi734/pkgmngr/etc/dnf/dnf.conf --best --releasever=39 --installroot=/tmp/aaa/.mkosi-tmpj9eoi734/root --setopt=keepcache=1 '--setopt=cachedir=/tmp/aaa/.mkosi-tmpj9eoi734/cache/fedora~39' --setopt=reposdir=/tmp/aaa/.mkosi-tmpj9eoi734/pkgmngr/etc/yum.repos.d --setopt=varsdir=/tmp/aaa/.mkosi-tmpj9eoi734/pkgmngr/etc/dnf/vars --setopt=persistdir=/tmp/aaa/.mkosi-tmpj9eoi734/pkgmngr/var/lib/dnf --setopt=check_config_file_age=0 '--disableplugin=*' --enableplugin=builddep --no-docs install filesystem" returned non-zero exit code 1.`

Also, the removal of `--config` is somewhat annoying. `-C` is a work-around, but then one needs to set `--workspace-dir` and `--output-dir` and possibly other settings. So I think it'd be nice to restore some option which allows a config file to be specified directly.


Discussion:

Resolving patch:
diff --git a/mkosi/run.py b/mkosi/run.py
--- a/mkosi/run.py
+++ b/mkosi/run.py
@@ -294,11 +294,11 @@ def bwrap(
             "--ro-bind", "/var", "/var",
             "--ro-bind", "/run", "/run",
             "--bind", "/var/tmp", "/var/tmp",
+            "--bind", "/tmp", "/tmp",
+            "--bind", Path.cwd(), Path.cwd(),
         ]
 
     cmdline += [
-        "--tmpfs", "/tmp",
-        "--bind", Path.cwd(), Path.cwd(),
         "--chdir", Path.cwd(),
         "--unshare-pid",
         "--unshare-ipc",
@@ -332,7 +332,7 @@ def bwrap(
         cmdline += [
             "--setenv", "PATH", f"{d}:{os.environ['PATH']}",
             *options,
-            "sh", "-c", "chmod 1777 /tmp /dev/shm && exec $0 \"$@\"",
+            "sh", "-c", "chmod 1777 /dev/shm && exec $0 \"$@\"",
         ]
 
         try:


Test patch: