Ejemplo n.º 1
0
 def _provision_package(self):
     context = self._config.context
     os.environ['DEBIAN_FRONTEND'] = 'noninteractive'
     if context.package.get('local_install', False):
         return apt_get_localinstall(context.package.arg)
     else:
         return apt_get_install(context.package.arg)
Ejemplo n.º 2
0
 def _provision_package(self):
     context = self._config.context
     os.environ['DEBIAN_FRONTEND'] = 'noninteractive'
     if context.package.get('local_install', False):
         return apt_get_localinstall(context.package.arg)
     else:
         return apt_get_install(context.package.arg)
Ejemplo n.º 3
0
def apt_get_localinstall(package):
    """install deb file with dpkg then resolve dependencies
    """
    dpkg_ret = dpkg_install(package)
    if not dpkg_ret.success:
        log.debug('failure:{0.command} :{0.stderr}'.format(dpkg_ret.result))
        return dpkg_ret

    apt_ret = apt_get_install('--fix-missing')
    if not apt_ret.success:
        log.debug('failure:{0.command} :{0.stderr}'.format(apt_ret.result))
    return apt_ret
Ejemplo n.º 4
0
def apt_get_localinstall(package):
    """install deb file with dpkg then resolve dependencies
    """
    dpkg_ret = dpkg_install(package)
    if not dpkg_ret.success:
        log.debug('failure:{0.command} :{0.stderr}'.format(dpkg_ret.result))
        return dpkg_ret

    apt_ret = apt_get_install('--fix-missing')
    if not apt_ret.success:
            log.debug('failure:{0.command} :{0.stderr}'.format(apt_ret.result))
    return apt_ret
Ejemplo n.º 5
0
 def _provision_package(self):
     context = self._config.context
     os.environ['DEBIAN_FRONTEND'] = 'noninteractive'
     return apt_get_install(context.package.arg)