mirror of
https://github.com/kevingruesser/bootstrap-vz.git
synced 2025-08-24 07:26:29 +00:00
Pulled disabling of daemonautostart into separate task
This commit is contained in:
parent
eec41422fc
commit
ba1fd93308
2 changed files with 11 additions and 3 deletions
|
@ -42,6 +42,7 @@ def tasks(tasklist, manifest):
|
||||||
filesystem.MountSpecials(),
|
filesystem.MountSpecials(),
|
||||||
locale.GenerateLocale(),
|
locale.GenerateLocale(),
|
||||||
locale.SetTimezone(),
|
locale.SetTimezone(),
|
||||||
|
apt.DisableDaemonAutostart(),
|
||||||
apt.AptSources(),
|
apt.AptSources(),
|
||||||
apt.AptUpgrade(),
|
apt.AptUpgrade(),
|
||||||
boot.ConfigureGrub(),
|
boot.ConfigureGrub(),
|
||||||
|
|
|
@ -22,10 +22,9 @@ class AptSources(Task):
|
||||||
release=info.manifest.system['release'])))
|
release=info.manifest.system['release'])))
|
||||||
|
|
||||||
|
|
||||||
class AptUpgrade(Task):
|
class DisableDaemonAutostart(Task):
|
||||||
description = 'Upgrading packages and fixing broken dependencies'
|
description = 'Disabling daemon autostart'
|
||||||
phase = phases.system_modification
|
phase = phases.system_modification
|
||||||
after = [GenerateLocale, AptSources]
|
|
||||||
|
|
||||||
def run(self, info):
|
def run(self, info):
|
||||||
rc_policy_path = os.path.join(info.root, 'usr/sbin/policy-rc.d')
|
rc_policy_path = os.path.join(info.root, 'usr/sbin/policy-rc.d')
|
||||||
|
@ -37,6 +36,14 @@ class AptUpgrade(Task):
|
||||||
stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR |
|
stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR |
|
||||||
stat.S_IRGRP | stat.S_IXGRP |
|
stat.S_IRGRP | stat.S_IXGRP |
|
||||||
stat.S_IROTH | stat.S_IXOTH)
|
stat.S_IROTH | stat.S_IXOTH)
|
||||||
|
|
||||||
|
|
||||||
|
class AptUpgrade(Task):
|
||||||
|
description = 'Upgrading packages and fixing broken dependencies'
|
||||||
|
phase = phases.system_modification
|
||||||
|
after = [GenerateLocale, AptSources, DisableDaemonAutostart]
|
||||||
|
|
||||||
|
def run(self, info):
|
||||||
log_check_call(['chroot', info.root, 'apt-get', 'update'])
|
log_check_call(['chroot', info.root, 'apt-get', 'update'])
|
||||||
log_check_call(['chroot', info.root, 'apt-get', '-f', '-y', 'install'])
|
log_check_call(['chroot', info.root, 'apt-get', '-f', '-y', 'install'])
|
||||||
log_check_call(['chroot', info.root, 'apt-get', '-y', 'upgrade'])
|
log_check_call(['chroot', info.root, 'apt-get', '-y', 'upgrade'])
|
||||||
|
|
Loading…
Add table
Reference in a new issue