diff options
author | Gonéri Le Bouder <goneri@lebouder.net> | 2020-03-26 16:07:51 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-26 16:07:51 -0400 |
commit | 44039629e539ed48298703028ac8f10ad3c60d6e (patch) | |
tree | c806fe54818f44148e6e37bf02cac1ea1e868610 /setup.py | |
parent | 4c88d9341e75a1a14ba2e8bd0ab309e265229f7e (diff) | |
download | vyos-cloud-init-44039629e539ed48298703028ac8f10ad3c60d6e.tar.gz vyos-cloud-init-44039629e539ed48298703028ac8f10ad3c60d6e.zip |
add Openbsd support (#147)
- tested on OpenBSD 6.6
- tested on OpenStack without config drive, and NoCloud with ISO config
drive
Diffstat (limited to 'setup.py')
-rwxr-xr-x | setup.py | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -15,6 +15,7 @@ import os import shutil import sys import tempfile +import platform import setuptools from setuptools.command.install import install @@ -230,7 +231,7 @@ class InitsysInstallData(install): if self.init_system and isinstance(self.init_system, str): self.init_system = self.init_system.split(",") - if len(self.init_system) == 0: + if len(self.init_system) == 0 and not platform.system().endswith('BSD'): self.init_system = ['systemd'] bad = [f for f in self.init_system if f not in INITSYS_TYPES] @@ -274,7 +275,7 @@ data_files = [ (USR + '/share/doc/cloud-init/examples/seed', [f for f in glob('doc/examples/seed/*') if is_f(f)]), ] -if os.uname()[0] not in ['FreeBSD', 'NetBSD']: +if not platform.system().endswith('BSD'): data_files.extend([ (ETC + '/NetworkManager/dispatcher.d/', ['tools/hook-network-manager']), |