summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
authorJames Falcon <therealfalcon@gmail.com>2021-07-19 14:13:21 -0500
committerGitHub <noreply@github.com>2021-07-19 14:13:21 -0500
commit184c836a16e9954a2cba11ae21f07923077ec904 (patch)
tree6289d70e4f833d300a25136dde6a56fcd1b0a0dc /setup.py
parenteacb0353803263934aa2ac827c37e461c87cb107 (diff)
downloadvyos-cloud-init-184c836a16e9954a2cba11ae21f07923077ec904.tar.gz
vyos-cloud-init-184c836a16e9954a2cba11ae21f07923077ec904.zip
Initial hotplug support (#936)
Adds a udev script which will invoke a hotplug hook script on all net add events. The script will write some udev arguments to a systemd FIFO socket (to ensure we have only instance of cloud-init running at a time), which is then read by a new service that calls a new 'cloud-init devel hotplug-hook' command to handle the new event. This hotplug-hook command will: - Fetch the pickled datsource - Verify that the hotplug event is supported/enabled - Update the metadata for the datasource - Ensure the hotplugged device exists within the datasource - Apply the config change on the datasource metadata - Bring up the new interface (or apply global network configuration) - Save the updated metadata back to the pickle cache Also scattered in some unrelated typing where helpful
Diffstat (limited to 'setup.py')
-rwxr-xr-xsetup.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/setup.py b/setup.py
index dcbe0843..7fa03e63 100755
--- a/setup.py
+++ b/setup.py
@@ -128,6 +128,7 @@ INITSYS_FILES = {
'systemd': [render_tmpl(f)
for f in (glob('systemd/*.tmpl') +
glob('systemd/*.service') +
+ glob('systemd/*.socket') +
glob('systemd/*.target'))
if (is_f(f) and not is_generator(f))],
'systemd.generators': [
@@ -249,6 +250,7 @@ data_files = [
(ETC + '/cloud/cloud.cfg.d', glob('config/cloud.cfg.d/*')),
(ETC + '/cloud/templates', glob('templates/*')),
(USR_LIB_EXEC + '/cloud-init', ['tools/ds-identify',
+ 'tools/hook-hotplug',
'tools/uncloud-init',
'tools/write-ssh-key-fingerprints']),
(USR + '/share/bash-completion/completions',