if source.is_dir():
copy_path(source, t, preserve_owner=False)
else:
- # unpack_archive() groks Paths, but mypy doesn't know this.
- # Pretend that tree is a str.
shutil.unpack_archive(source, t)
state.root.joinpath("etc/apt/sources.list.d/mirror.list").unlink()
cls._add_apt_auxiliary_repos(state, repos)
- # Don't enable any services by default.
+ # Make sure preset doesn't touch services unless explicitly configured.
presetdir = state.root / "etc/systemd/system-preset"
presetdir.mkdir(exist_ok=True, mode=0o755)
presetdir.joinpath("99-mkosi-ignore.preset").write_text("ignore *")
if source.is_dir():
copy_path(source, t, preserve_owner=False)
else:
- # unpack_archive() groks Paths, but mypy doesn't know this.
- # Pretend that tree is a str.
shutil.unpack_archive(source, t)