|
|
|
@ -300,7 +300,7 @@ class VariableClUpdateBinhostData(ReadonlyTableVariable):
|
|
|
|
|
|
|
|
|
|
def get(self, hr=HumanReadable.No):
|
|
|
|
|
last_ts = self.Get('cl_update_last_timestamp')
|
|
|
|
|
if self.GetBool('cl_update_binhost_stable_set'):
|
|
|
|
|
if self.GetBool('cl_update_binhost_stable_opt_set'):
|
|
|
|
|
binhost_list = self.Get('cl_update_binhost_list')
|
|
|
|
|
else:
|
|
|
|
|
binhost_list = self.Get('cl_update_binhost_unstable_list')
|
|
|
|
@ -324,10 +324,6 @@ class VariableClUpdateBinhostData(ReadonlyTableVariable):
|
|
|
|
|
|
|
|
|
|
logger = self.get_logger(stub=binhosts_data.is_cache())
|
|
|
|
|
ret_val = None
|
|
|
|
|
# TODO: важно еще сверу коммент
|
|
|
|
|
# отладочная строка
|
|
|
|
|
# необходимо разобраться почему calculate-builder вызывает
|
|
|
|
|
# заполнение несколько раз!!!!!!!!!!!!
|
|
|
|
|
logger.info("Started scan on: {date}, current timestamp: {ts}".format(
|
|
|
|
|
date=time.ctime(), ts=last_ts))
|
|
|
|
|
for host, ts, t, good, downgrade in binhosts_data.get_sorted():
|
|
|
|
@ -1313,6 +1309,7 @@ class DataVarsUpdateProfile(SimpleDataVars):
|
|
|
|
|
VariableClUpdateBinhostList(section="update"),
|
|
|
|
|
VariableClUpdateBinhostUnstableList(section="update"),
|
|
|
|
|
VariableClUpdateBinhostStableSet(section="update"),
|
|
|
|
|
VariableClUpdateBinhostStableOptSet(section="update"),
|
|
|
|
|
VariableClUpdateBinhostRevisionPath(section="update"),
|
|
|
|
|
)
|
|
|
|
|
self['cl_profile_system'] = profile
|
|
|
|
@ -1320,7 +1317,7 @@ class DataVarsUpdateProfile(SimpleDataVars):
|
|
|
|
|
if recheck is not None:
|
|
|
|
|
self['cl_update_binhost_recheck_set'] = recheck
|
|
|
|
|
if stable is not None:
|
|
|
|
|
self['cl_update_binhost_stable_set'] = stable
|
|
|
|
|
self['cl_update_binhost_stable_opt_set'] = stable
|
|
|
|
|
self.flIniFileFrom(profile)
|
|
|
|
|
|
|
|
|
|
def __repr__(self):
|
|
|
|
@ -1520,7 +1517,6 @@ class VariableClUpdateBinhostUnstableList(Variable):
|
|
|
|
|
type = "list"
|
|
|
|
|
value = ["ftp://ftp.calculate-linux.ru/testing"]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateBinhostStableSet(Variable):
|
|
|
|
|
"""
|
|
|
|
|
Удлять лишние файлы из репозиториев (например созданные пользователем)
|
|
|
|
@ -1528,12 +1524,22 @@ class VariableClUpdateBinhostStableSet(Variable):
|
|
|
|
|
type = "bool"
|
|
|
|
|
value = "on"
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateBinhostStableOptSet(Variable):
|
|
|
|
|
"""
|
|
|
|
|
Удлять лишние файлы из репозиториев (например созданные пользователем)
|
|
|
|
|
"""
|
|
|
|
|
type = "bool"
|
|
|
|
|
value = "on"
|
|
|
|
|
|
|
|
|
|
opt = ["--stable"]
|
|
|
|
|
|
|
|
|
|
def init(self):
|
|
|
|
|
self.label = _("Check the repositories integrity")
|
|
|
|
|
self.help = _("use only stable updates")
|
|
|
|
|
|
|
|
|
|
def get(self):
|
|
|
|
|
return self.Get('cl_update_binhost_stable_set')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class VariableClUpdateBinhost(Variable):
|
|
|
|
|
"""
|
|
|
|
|