fix issue where apt-update was not done unless explicitly set
This commit is contained in:
parent
56d68e4276
commit
a61ea3d773
@ -1,3 +1,6 @@
|
||||
0.6.2:
|
||||
- fix bug where update was not done unless update was explicitly set.
|
||||
It would not be run if 'upgrade' or packages were set to be installed
|
||||
0.6.1:
|
||||
- fix bug in fixing permission on /var/log/cloud-init.log (LP: #704509)
|
||||
- improve comment strings in rsyslog file tools/21-cloudinit.conf
|
||||
|
@ -55,8 +55,10 @@ def handle(name,cfg,cloud,log,args):
|
||||
log.error("Failed to run debconf-set-selections")
|
||||
log.debug(traceback.format_exc())
|
||||
|
||||
pkglist = util.get_cfg_option_list_or_str(cfg,'packages',[])
|
||||
|
||||
errors = [ ]
|
||||
if update:
|
||||
if update or len(pkglist) or upgrade:
|
||||
try:
|
||||
cc.update_package_sources()
|
||||
except subprocess.CalledProcessError as e:
|
||||
@ -72,7 +74,6 @@ def handle(name,cfg,cloud,log,args):
|
||||
log.debug(traceback.format_exc())
|
||||
errors.append(e)
|
||||
|
||||
pkglist = util.get_cfg_option_list_or_str(cfg,'packages',[])
|
||||
if len(pkglist):
|
||||
try:
|
||||
cc.install_packages(pkglist)
|
||||
|
Loading…
x
Reference in New Issue
Block a user