From: Frank Brehm Date: Fri, 10 Nov 2023 12:56:23 +0000 (+0100) Subject: Extending setup.py by installing SSH deploy keys X-Git-Tag: 1.8.0^2~13 X-Git-Url: https://git.uhu-banane.de/?a=commitdiff_plain;h=65b93c9b7ead618192dbcc5ab4fcdda29edd1eff;p=pixelpark%2Fcreate-terraform.git Extending setup.py by installing SSH deploy keys --- diff --git a/setup.py b/setup.py index 1cf7587..e306f81 100644 --- a/setup.py +++ b/setup.py @@ -28,6 +28,7 @@ __lib_dir__ = os.path.join(__base_dir__, 'lib') __module_dir__ = os.path.join(__lib_dir__, 'cr_tf') __init_py__ = os.path.join(__module_dir__, '__init__.py') __postinst_scriptdir__ = pathlib.Path(__base_dir__) / 'postinstall-scripts' +__keys_dir__ = pathlib.Path(__base_dir__) / 'keys' PATHS = { '__base_dir__': __base_dir__, @@ -152,6 +153,14 @@ for f in __postinst_scriptdir__.glob('*'): if __pi_scripts__: __data_files__.append(('postinstall-scripts', __pi_scripts__)) +__keys__ = [] +for f in __keys_dir__.glob('*'): + if f.is_file() and os.access(str(f), os.R_OK): + relpath = os.path.relpath(str(f), __base_dir__) + __keys__.append(relpath) +if __keys__: + __data_files__.append(('keys', __keys__)) + # print("Found data files:\n" + pp(__data_files__) + "\n")