All stages must be able to handle an input_dir argument, as we now either pass it to all or none for agiven run. Simply set it to 'None' if it is not provided. Signed-off-by: Tom Gundersen <teg@jklm.no>
15 lines
341 B
Python
Executable file
15 lines
341 B
Python
Executable file
#!/usr/bin/python3
|
|
|
|
import contextlib
|
|
import json
|
|
import os
|
|
import sys
|
|
|
|
def main(tree, inut_dir):
|
|
with contextlib.suppress(FileNotFoundError):
|
|
os.unlink(f"{tree}/etc/machine-id")
|
|
os.unlink(f"{tree}/var/lib/systemd/random-seed")
|
|
|
|
if __name__ == '__main__':
|
|
options = json.load(sys.stdin)
|
|
sys.exit(main(**options))
|