old_contents: import mon  # noqa
  from install import install, mirror_install, repo_install  # noqa
  from uninstall import uninstall  # noqa
  from ceph_deploy.util import pkg_managers
  
  # Allow to set some information about this distro
  #
  
  distro = None
  release = None
  codename = None
  
  def choose_init(module):
      """
      Select a init system
  
      Returns the name of a init system (upstart, sysvinit ...).
      """
      # fixme: newer ubuntu runs systemd
      if distro.lower() == 'ubuntu':
          return 'upstart'
      if module.conn.remote_module.path_exists("/lib/systemd/system/ceph.target"):
          return 'systemd'
      return 'sysvinit'
  
  
  def get_packager(module):
      return pkg_managers.Apt(module)
  
new_contents: import mon  # noqa
  from install import install, mirror_install, repo_install  # noqa
  from uninstall import uninstall  # noqa
  from ceph_deploy.util import pkg_managers
  from ceph_deploy.util.system import is_systemd, is_upstart
  
  # Allow to set some information about this distro
  #
  
  distro = None
  release = None
  codename = None
  
  
  def choose_init(module):
      """
      Select a init system
  
      Returns the name of a init system (upstart, sysvinit ...).
      """
      if is_systemd(module.conn) or module.conn.remote_module.path_exists(
              "/lib/systemd/system/ceph.target"):
          return 'systemd'
  
      if is_upstart(module.conn):
          return 'upstart'
  
      return 'sysvinit'
  
  
  def get_packager(module):
      return pkg_managers.Apt(module)
  
subject: use is_upstart detection on debian init check