simplify and creole => rougail

This commit is contained in:
Emmanuel Garette 2020-02-16 21:27:42 +01:00
parent d8e99fef54
commit 9bb1a8c26a
342 changed files with 1522 additions and 869 deletions

View File

@ -37,7 +37,7 @@
<!-- root element --> <!-- root element -->
<!-- =============== --> <!-- =============== -->
<!ELEMENT creole (services | family_action | variables | constraints | help)*> <!ELEMENT rougail (services | family_action | variables | constraints | help)*>
<!-- ============== --> <!-- ============== -->
<!-- files element --> <!-- files element -->
@ -66,7 +66,7 @@
<!ELEMENT services (service*)> <!ELEMENT services (service*)>
<!ELEMENT service ((port* | tcpwrapper* | ip* | interface* | package* | file*)*) > <!ELEMENT service ((port* | tcpwrapper* | ip* | interface* | package* | file* | digitalcertificate*)*) >
<!ATTLIST service name CDATA #REQUIRED> <!ATTLIST service name CDATA #REQUIRED>
<!ATTLIST service method (systemd|upstart|apache|network) "systemd"> <!ATTLIST service method (systemd|upstart|apache|network) "systemd">
@ -78,37 +78,23 @@
<!ELEMENT port (#PCDATA)> <!ELEMENT port (#PCDATA)>
<!ATTLIST port port_type (PortOption|SymLinkOption|variable) "PortOption"> <!ATTLIST port port_type (PortOption|SymLinkOption|variable) "PortOption">
<!ATTLIST port service_accesslist CDATA #IMPLIED > <!ATTLIST port portlist CDATA #IMPLIED >
<!ATTLIST port protocol (tcp|udp) "tcp"> <!ATTLIST port protocol (tcp|udp) "tcp">
<!ELEMENT tcpwrapper (#PCDATA)> <!ELEMENT tcpwrapper (#PCDATA)>
<!ATTLIST tcpwrapper tcpwrapper_type (UnicodeOption|SymLinkOption|variable) "UnicodeOption"> <!ATTLIST tcpwrapper tcpwrapper_type (UnicodeOption|SymLinkOption|variable) "UnicodeOption">
<!ATTLIST tcpwrapper service_accesslist CDATA #IMPLIED > <!ATTLIST tcpwrapper tcpwrapperlist CDATA #IMPLIED >
<!ELEMENT ip (#PCDATA)> <!ELEMENT ip (#PCDATA)>
<!ATTLIST ip service_restrictionlist CDATA #IMPLIED > <!ATTLIST ip iplist CDATA #IMPLIED >
<!ATTLIST ip ip_type (NetworkOption|SymLinkOption|variable) "NetworkOption"> <!ATTLIST ip ip_type (NetworkOption|SymLinkOption|variable) "NetworkOption">
<!ATTLIST ip interface_type (UnicodeOption|SymLinkOption|variable) "UnicodeOption"> <!ATTLIST ip interface_type (UnicodeOption|SymLinkOption|variable) "UnicodeOption">
<!ATTLIST ip interface CDATA #REQUIRED> <!ATTLIST ip interface CDATA #REQUIRED>
<!ATTLIST ip netmask_type (NetmaskOption|SymLinkOption|variable) "NetmaskOption"> <!ATTLIST ip netmask_type (NetmaskOption|SymLinkOption|variable) "NetmaskOption">
<!ATTLIST ip netmask CDATA "255.255.255.255"> <!ATTLIST ip netmask CDATA "255.255.255.255">
<!ELEMENT interface (#PCDATA)>
<!ATTLIST interface interfacelist CDATA #IMPLIED >
<!ATTLIST interface linkto CDATA #REQUIRED >
<!ATTLIST interface ip CDATA #REQUIRED>
<!ATTLIST interface ip_type (SymLinkOption|variable) "variable">
<!ATTLIST interface mask CDATA #REQUIRED>
<!ATTLIST interface mask_type (SymLinkOption|variable) "variable">
<!ATTLIST interface bcast CDATA #IMPLIED>
<!ATTLIST interface bcast_type (SymLinkOption|variable) "variable">
<!ATTLIST interface gateway CDATA #IMPLIED>
<!ATTLIST interface gateway_type (variable) "variable">
<!ATTLIST interface method (bridge|macvlan) "macvlan" >
<!ATTLIST interface redefine (True|False) "False">
<!ELEMENT package (#PCDATA)> <!ELEMENT package (#PCDATA)>
<!ATTLIST package packagelist CDATA #IMPLIED> <!ATTLIST package packagelist CDATA #IMPLIED >
<!ELEMENT file EMPTY> <!ELEMENT file EMPTY>
<!ATTLIST file name CDATA #REQUIRED > <!ATTLIST file name CDATA #REQUIRED >
@ -116,15 +102,22 @@
<!ATTLIST file variable CDATA #IMPLIED> <!ATTLIST file variable CDATA #IMPLIED>
<!ATTLIST file variable_type (variable) "variable"> <!ATTLIST file variable_type (variable) "variable">
<!ATTLIST file source CDATA #IMPLIED> <!ATTLIST file source CDATA #IMPLIED>
<!ATTLIST file mode CDATA #IMPLIED > <!ATTLIST file mode CDATA "0644">
<!ATTLIST file owner CDATA #IMPLIED > <!ATTLIST file owner CDATA "root">
<!ATTLIST file group CDATA #IMPLIED > <!ATTLIST file group CDATA "root">
<!ATTLIST file filelist CDATA #IMPLIED > <!ATTLIST file filelist CDATA #IMPLIED >
<!ATTLIST file mkdir (True|False) "False"> <!ATTLIST file mkdir (True|False) "False">
<!ATTLIST file rm (True|False) "False"> <!ATTLIST file rm (True|False) "False">
<!ATTLIST file del_comment CDATA #IMPLIED >
<!ATTLIST file redefine (True|False) "False"> <!ATTLIST file redefine (True|False) "False">
<!ELEMENT digitalcertificate EMPTY>
<!ATTLIST digitalcertificate name CDATA #REQUIRED >
<!ATTLIST digitalcertificate digitalcertificate_type (variable) "variable">
<!ATTLIST digitalcertificate certificate CDATA #REQUIRED >
<!ATTLIST digitalcertificate certificate_type (variable) "variable">
<!ATTLIST digitalcertificate type CDATA #REQUIRED >
<!ATTLIST digitalcertificate ca CDATA #REQUIRED >
<!ELEMENT variables (family*, separators*)> <!ELEMENT variables (family*, separators*)>
<!ELEMENT family (#PCDATA | variable)*> <!ELEMENT family (#PCDATA | variable)*>
<!ATTLIST family name CDATA #REQUIRED> <!ATTLIST family name CDATA #REQUIRED>
@ -183,13 +176,13 @@
<!ATTLIST group description CDATA #IMPLIED> <!ATTLIST group description CDATA #IMPLIED>
<!ELEMENT param (#PCDATA)> <!ELEMENT param (#PCDATA)>
<!ATTLIST param type (string|eole|variable|number|python) "string"> <!ATTLIST param type (string|variable|number|python) "string">
<!ATTLIST param name CDATA #IMPLIED> <!ATTLIST param name CDATA #IMPLIED>
<!ATTLIST param hidden (True|False) "True"> <!ATTLIST param hidden (True|False) "True">
<!ATTLIST param optional (True|False) "False"> <!ATTLIST param optional (True|False) "False">
<!ELEMENT target (#PCDATA)> <!ELEMENT target (#PCDATA)>
<!ATTLIST target type (family|filelist|servicelist|interfacelist|variable|service_accesslist|service_restrictionlist|hostlist|fstablist|actionlist) "variable"> <!ATTLIST target type (family|variable|filelist|iplist|portlist|tcpwrapperlist|packagelist|actionlist) "variable">
<!ATTLIST target optional (True|False) "False"> <!ATTLIST target optional (True|False) "False">
<!ELEMENT slave (#PCDATA)> <!ELEMENT slave (#PCDATA)>

View File

@ -112,15 +112,10 @@ class ServiceAnnotator:
del self.space.services del self.space.services
def convert_service_to_family(self, service_name, service_family, service): def convert_service_to_family(self, service_name, service_family, service):
# tranform service object to family object
# add services, service_accesses, ...
for elttype, values in vars(service).items(): for elttype, values in vars(service).items():
if elttype in ['name', 'index']: if elttype in ['name', 'index']:
continue continue
family = self.objectspace.family() family = self.objectspace.family()
if elttype.endswith('s'):
family.name = elttype + 'es'
else:
family.name = elttype + 's' family.name = elttype + 's'
if isinstance(values, dict): if isinstance(values, dict):
values = list(values.values()) values = list(values.values())
@ -204,7 +199,6 @@ class ServiceAnnotator:
var_data['type'] = type_ var_data['type'] = type_
variable = self.objectspace.variable() variable = self.objectspace.variable()
if not HIGH_COMPATIBILITY:
variable.mandatory = True variable.mandatory = True
for key, value in var_data.items(): for key, value in var_data.items():
if key == 'value': if key == 'value':
@ -248,17 +242,13 @@ class ServiceAnnotator:
'for {}').format(file_.name)) 'for {}').format(file_.name))
def _reorder_elts(self, name, elts, duplicate_list): def _reorder_elts(self, name, elts, duplicate_list):
"""Reorders by index the elts (the interface, """Reorders by index the elts
the hosts, actions...)
""" """
dict_elts = OrderedDict() dict_elts = OrderedDict()
# reorder elts by index # reorder elts by index
new_elts = {} new_elts = {}
not_indexed = [] not_indexed = []
for elt in elts: for elt in elts:
if not hasattr(elt, 'index'):
not_indexed.append(elt)
else:
idx = elt.index idx = elt.index
new_elts.setdefault(idx, []).append(elt) new_elts.setdefault(idx, []).append(elt)
idxes = list(new_elts.keys()) idxes = list(new_elts.keys())
@ -273,10 +263,7 @@ class ServiceAnnotator:
continue continue
value = getattr(elt, key) value = getattr(elt, key)
if not elt_added: if not elt_added:
if hasattr(elt, 'name'):
eltname = elt.name eltname = elt.name
else:
eltname = idx
dict_elts.setdefault(eltname, []).append({'elt_name': name, 'elt': elt}) dict_elts.setdefault(eltname, []).append({'elt_name': name, 'elt': elt})
result_elts = [] result_elts = []
@ -397,7 +384,7 @@ class SpaceAnnotator(object):
self.has_calc = [] self.has_calc = []
self.force_no_value = [] self.force_no_value = []
self.force_not_mandatory = [] self.force_not_mandatory = []
if eosfunc_file is not None: if eosfunc_file:
self.eosfunc = imp.load_source('eosfunc', eosfunc_file) self.eosfunc = imp.load_source('eosfunc', eosfunc_file)
else: else:
self.eosfunc = None self.eosfunc = None
@ -544,9 +531,6 @@ class SpaceAnnotator(object):
variable_mode = variable.mode variable_mode = variable.mode
if variable_mode is not None and modes[mode] > modes[variable_mode]: if variable_mode is not None and modes[mode] > modes[variable_mode]:
mode = variable_mode mode = variable_mode
if family.name == 'Containers':
family.mode = 'normal'
else:
family.mode = mode family.mode = mode
def dynamic_families(self): # pylint: disable=C0111 def dynamic_families(self): # pylint: disable=C0111
@ -585,8 +569,6 @@ class SpaceAnnotator(object):
variable.mode = family_mode variable.mode = family_mode
if variable.mode != None and variable.mode != modes_level[0] and modes[variable.mode] < modes[family_mode]: if variable.mode != None and variable.mode != modes_level[0] and modes[variable.mode] < modes[family_mode]:
variable.mode = family_mode variable.mode = family_mode
if variable.name == "available_probes":
variable.force_default_on_freeze = False
def default_variable_options(self): def default_variable_options(self):
if hasattr(self.space, 'variables'): if hasattr(self.space, 'variables'):
@ -727,19 +709,9 @@ class SpaceAnnotator(object):
is_follower = False is_follower = False
path = '{}.{}.{}'.format(family.path, variable.name, follower.name) path = '{}.{}.{}'.format(family.path, variable.name, follower.name)
self._annotate_variable(follower, family_mode, path, is_follower) self._annotate_variable(follower, family_mode, path, is_follower)
if HIGH_COMPATIBILITY: # leader's mode is minimum level
# leader's variable are right
if modes[variable.variable[0].mode] > modes[follower.mode]: if modes[variable.variable[0].mode] > modes[follower.mode]:
follower.mode = variable.variable[0].mode follower.mode = variable.variable[0].mode
else:
# auto_save's variable is set in 'basic' mode if its mode is 'normal'
if follower.auto_save is True and follower.mode != modes_level[-1]:
follower.mode = modes_level[0]
if modes[mode] > modes[follower.mode]:
mode = follower.mode
if not HIGH_COMPATIBILITY:
# the leader's mode is the lowest
variable.variable[0].mode = mode
variable.mode = variable.variable[0].mode variable.mode = variable.variable[0].mode
else: else:
# auto_save's variable is set in 'basic' mode if its mode is 'normal' # auto_save's variable is set in 'basic' mode if its mode is 'normal'
@ -770,13 +742,9 @@ class SpaceAnnotator(object):
# sort fill/auto by index # sort fill/auto by index
if 'fill' in vars(constraints): if 'fill' in vars(constraints):
for idx, fill in enumerate(constraints.fill): for idx, fill in enumerate(constraints.fill):
if fill.index in fills:
raise Exception('hu?')
fills[fill.index] = {'idx': idx, 'fill': fill, 'type': 'fill'} fills[fill.index] = {'idx': idx, 'fill': fill, 'type': 'fill'}
if 'auto' in vars(constraints): if 'auto' in vars(constraints):
for idx, fill in enumerate(constraints.auto): for idx, fill in enumerate(constraints.auto):
if fill.index in fills:
raise Exception('hu?')
fills[fill.index] = {'idx': idx, 'fill': fill, 'type': 'auto'} fills[fill.index] = {'idx': idx, 'fill': fill, 'type': 'auto'}
indexes = list(fills.keys()) indexes = list(fills.keys())
indexes.sort() indexes.sort()
@ -785,10 +753,7 @@ class SpaceAnnotator(object):
remove_fills = [] remove_fills = []
for idx in indexes: for idx in indexes:
fill = fills[idx]['fill'] fill = fills[idx]['fill']
if hasattr(fill, 'redefine'):
redefine = bool(fill.redefine) redefine = bool(fill.redefine)
else:
redefine = False
if fill.target in targets: if fill.target in targets:
if redefine: if redefine:
if targets[fill.target][1] == 'auto': if targets[fill.target][1] == 'auto':
@ -972,8 +937,6 @@ class SpaceAnnotator(object):
'').format(check.target)) '').format(check.target))
param = check.param[0] param = check.param[0]
if proposed_value_type: if proposed_value_type:
if param.type == 'eole':
raise Exception('hu?')
if param.type == 'variable': if param.type == 'variable':
try: try:
values = self.load_params_in_validenum(param) values = self.load_params_in_validenum(param)

View File

@ -3,18 +3,19 @@
fichier de configuration pour créole fichier de configuration pour créole
""" """
from os.path import join, isfile from os.path import join, isfile, abspath, dirname
from pathlib import Path
eoleroot = join('.') eoleroot = dirname(abspath(join(__file__, '..', '..')))
# chemin du répertoire source des fichiers templates # chemin du répertoire source des fichiers templates
patch_dir = join(eoleroot, 'patch') patch_dir = join(eoleroot, 'patch')
# repertoire de la dtd # repertoire de la dtd
dtddir = '/usr/share/creole' dtddir = '/usr/share/rougail'
if isfile('data/creole.dtd'): if isfile(join(eoleroot, 'data/rougail.dtd')):
dtdfilename = 'data/creole.dtd' dtdfilename = join(eoleroot, 'data/rougail.dtd')
elif isfile('../creole/data/creole.dtd'): elif isfile('../rougail/data/rougail.dtd'):
dtdfilename = '../creole/data/creole.dtd' dtdfilename = '../rougail/data/rougail.dtd'
else: else:
dtdfilename = join(dtddir, 'creole.dtd') dtdfilename = join(dtddir, 'rougail.dtd')

View File

@ -124,6 +124,9 @@ class PopulateTiramisuObjects(object):
def make_tiramisu_objects(self, xmlroot, creolefunc_file): def make_tiramisu_objects(self, xmlroot, creolefunc_file):
elt = Elt({'name': 'baseoption'}) elt = Elt({'name': 'baseoption'})
if creolefunc_file is None:
self.eosfunc = None
else:
self.eosfunc = imp.load_source('eosfunc', creolefunc_file) self.eosfunc = imp.load_source('eosfunc', creolefunc_file)
family = Family(elt, self.booleans, self.storage, self.eosfunc) family = Family(elt, self.booleans, self.storage, self.eosfunc)
self.storage.add('.', family) self.storage.add('.', family)
@ -308,6 +311,7 @@ class Variable(Common):
self.attrib['validators'] = [] self.attrib['validators'] = []
self.eosfunc = eosfunc self.eosfunc = eosfunc
self.storage = storage self.storage = storage
is_submulti = False
for key, value in elt.attrib.items(): for key, value in elt.attrib.items():
if key in booleans: if key in booleans:
if value == 'True': if value == 'True':
@ -315,6 +319,7 @@ class Variable(Common):
elif value == 'False': elif value == 'False':
value = False value = False
elif key == 'multi' and value == 'submulti': elif key == 'multi' and value == 'submulti':
is_submulti = True
value = submulti value = submulti
else: else:
raise CreoleLoaderError(_('unknown value {} for {}').format(value, key)) raise CreoleLoaderError(_('unknown value {} for {}').format(value, key))
@ -364,13 +369,22 @@ class Variable(Common):
type_ = CONVERT_OPTION[child.attrib['type']]['opttype'] type_ = CONVERT_OPTION[child.attrib['type']]['opttype']
else: else:
type_ = self.object_type type_ = self.object_type
if self.attrib['multi'] and not is_follower: if self.attrib['multi'] is True and not is_follower:
if 'default' not in self.attrib: if 'default' not in self.attrib:
self.attrib['default'] = [] self.attrib['default'] = []
value = convert_tiramisu_value(child.text, type_) value = convert_tiramisu_value(child.text, type_)
self.attrib['default'].append(value) self.attrib['default'].append(value)
if 'default_multi' not in self.attrib and not is_leader: if 'default_multi' not in self.attrib and not is_leader:
self.attrib['default_multi'] = value self.attrib['default_multi'] = value
elif self.attrib['multi'] == submulti:
if 'default' not in self.attrib:
self.attrib['default'] = []
value = convert_tiramisu_value(child.text, type_)
if not isinstance(value, list) and not is_follower:
value = [value]
self.attrib['default'].append(value)
if 'default_multi' not in self.attrib and not is_leader:
self.attrib['default_multi'] = value
else: else:
if 'default' in self.attrib: if 'default' in self.attrib:
raise CreoleLoaderError(_('default value already set for {}' raise CreoleLoaderError(_('default value already set for {}'

View File

@ -39,7 +39,7 @@ FORCE_REDEFINABLES = ('family', 'slave', 'service', 'disknod', 'variables', 'fam
# CreoleObjSpace's elements that shall be forced to the UnRedefinable type # CreoleObjSpace's elements that shall be forced to the UnRedefinable type
FORCE_UNREDEFINABLES = ('value', 'input', 'profile', 'ewtapp', 'tag', 'saltaction') FORCE_UNREDEFINABLES = ('value', 'input', 'profile', 'ewtapp', 'tag', 'saltaction')
# CreoleObjSpace's elements that shall be set to the UnRedefinable type # CreoleObjSpace's elements that shall be set to the UnRedefinable type
UNREDEFINABLE = ('multi', 'type') UNREDEFINABLE = ('submulti', 'multi', 'type')
PROPERTIES = ('hidden', 'frozen', 'auto_freeze', 'auto_save', 'force_default_on_freeze', PROPERTIES = ('hidden', 'frozen', 'auto_freeze', 'auto_save', 'force_default_on_freeze',
'force_store_value', 'disabled', 'mandatory') 'force_store_value', 'disabled', 'mandatory')
@ -47,6 +47,8 @@ CONVERT_PROPERTIES = {'auto_save': ['force_store_value'], 'auto_freeze': ['force
RENAME_ATTIBUTES = {'description': 'doc'} RENAME_ATTIBUTES = {'description': 'doc'}
INCOMPATIBLE_ATTRIBUTES = [['multi', 'submulti']]
#TYPE_TARGET_CONDITION = ('variable', 'family') #TYPE_TARGET_CONDITION = ('variable', 'family')
# _____________________________________________________________________________ # _____________________________________________________________________________
@ -88,8 +90,6 @@ class CreoleObjSpace(object):
# ['variable', 'separator', 'family'] # ['variable', 'separator', 'family']
self.forced_text_elts = set() self.forced_text_elts = set()
# ['disknod', 'follower', 'target', 'service', 'package', 'ip', 'value', 'tcpwrapper',
# 'interface', 'input', 'port']
self.forced_text_elts_as_name = set(['choice', 'property']) self.forced_text_elts_as_name = set(['choice', 'property'])
self.forced_choice_option = {} self.forced_choice_option = {}
self.paths = Path() self.paths = Path()
@ -357,6 +357,15 @@ class CreoleObjSpace(object):
'not {}').format(attr, val)) 'not {}').format(attr, val))
if not (attr == 'name' and getattr(creoleobj, 'name', None) != None): if not (attr == 'name' and getattr(creoleobj, 'name', None) != None):
setattr(creoleobj, attr, val) setattr(creoleobj, attr, val)
keys = list(vars(creoleobj).keys())
for incompatible in INCOMPATIBLE_ATTRIBUTES:
found = False
for inc in incompatible:
if inc in keys:
if found:
raise CreoleDictConsistencyError(_('those attributes are incompatible {}').format(incompatible))
found = True
def _creoleobj_tree_visitor(self, child, creoleobj, namespace): def _creoleobj_tree_visitor(self, child, creoleobj, namespace):
"""Creole object tree manipulations """Creole object tree manipulations

View File

@ -17,11 +17,13 @@ from os.path import dirname, basename, join, split, isfile, isdir
from tempfile import mktemp from tempfile import mktemp
from Cheetah import Parser from Cheetah import Parser
# l'encoding du template est déterminé par une regexp (encodingDirectiveRE dans Parser.py) # l'encoding du template est déterminé par une regexp (encodingDirectiveRE dans Parser.py)
# il cherche un ligne qui ressemble à '#encoding: utf-8 # il cherche un ligne qui ressemble à '#encoding: utf-8
# cette classe simule le module 're' et retourne toujours l'encoding utf-8 # cette classe simule le module 're' et retourne toujours l'encoding utf-8
# 6224 # 6224
class FakeEncoding(): class FakeEncoding:
def groups(self): def groups(self):
return ('utf-8',) return ('utf-8',)
@ -29,6 +31,7 @@ class FakeEncoding():
return self return self
Parser.encodingDirectiveRE = FakeEncoding() Parser.encodingDirectiveRE = FakeEncoding()
from Cheetah.Template import Template as ChtTemplate from Cheetah.Template import Template as ChtTemplate
from Cheetah.NameMapper import NotFound as CheetahNotFound from Cheetah.NameMapper import NotFound as CheetahNotFound
@ -120,7 +123,6 @@ class CheetahTemplate(ChtTemplate):
""" """
extra_context = {'is_defined' : IsDefined(context), extra_context = {'is_defined' : IsDefined(context),
# 'creole_client' : CreoleClient(config), # 'creole_client' : CreoleClient(config),
# 'current_container':CreoleGet(current_container),
'normalize_family': normalize_family, 'normalize_family': normalize_family,
'rougail_filename': destfilename 'rougail_filename': destfilename
} }
@ -266,6 +268,7 @@ class CreoleTemplateEngine:
self.tmp_dir = tmp_dir self.tmp_dir = tmp_dir
self.distrib_dir = distrib_dir self.distrib_dir = distrib_dir
eos = {} eos = {}
if eosfunc_file is not None:
eosfunc = imp.load_source('eosfunc', eosfunc_file) eosfunc = imp.load_source('eosfunc', eosfunc_file)
for func in dir(eosfunc): for func in dir(eosfunc):
if not func.startswith('_'): if not func.startswith('_'):
@ -274,7 +277,6 @@ class CreoleTemplateEngine:
self.creole_variables_dict = {} self.creole_variables_dict = {}
async def load_eole_variables_creole(self, async def load_eole_variables_creole(self,
config,
optiondescription): optiondescription):
for option in await optiondescription.list('all'): for option in await optiondescription.list('all'):
if await option.option.isoptiondescription(): if await option.option.isoptiondescription():
@ -284,17 +286,15 @@ class CreoleTemplateEngine:
leader = CreoleLeader(await suboption.value.get()) leader = CreoleLeader(await suboption.value.get())
self.creole_variables_dict[await suboption.option.name()] = leader self.creole_variables_dict[await suboption.option.name()] = leader
else: else:
await leader.add_slave(config, await leader.add_slave(self.config,
await suboption.option.name(), await suboption.option.name(),
await suboption.option.path()) await suboption.option.path())
else: else:
await self.load_eole_variables_creole(config, await self.load_eole_variables_creole(option)
option)
else: else:
self.creole_variables_dict[await option.option.name()] = await option.value.get() self.creole_variables_dict[await option.option.name()] = await option.value.get()
async def load_eole_variables(self, async def load_eole_variables(self,
config,
namespace, namespace,
optiondescription): optiondescription):
families = {} families = {}
@ -307,7 +307,7 @@ class CreoleTemplateEngine:
leader = CreoleLeader(await suboption.value.get()) leader = CreoleLeader(await suboption.value.get())
leader_name = await suboption.option.name() leader_name = await suboption.option.name()
else: else:
await leader.add_slave(config, await leader.add_slave(self.config,
await suboption.option.name(), await suboption.option.name(),
await suboption.option.path()) await suboption.option.path())
variables[leader_name] = leader variables[leader_name] = leader
@ -334,24 +334,6 @@ class CreoleTemplateEngine:
log.error(_(f"Error applying patch: '{patch_file}'\nTo reproduce and fix this error {patch_cmd_err}")) log.error(_(f"Error applying patch: '{patch_file}'\nTo reproduce and fix this error {patch_cmd_err}"))
copy(filename, self.tmp_dir) copy(filename, self.tmp_dir)
def strip_template_comment(self,
filename: str):
"""Strip comment from template
This apply if filevar has a del_comment attribut
"""
# suppression des commentaires si demandé (attribut del_comment)
if 'del_comment' in filevar and filevar['del_comment'] != '':
strip_cmd = ['sed', '-i']
log.info(_("Cleaning file '{0}'").format( filevar['source'] ))
raise Exception('hu')
#ret, out, err = pyeole.process.system_out(strip_cmd
# + ['/^\s*{0}/d ; /^$/d'.format(filevar['del_comment']),
# filevar['source'] ])
#if ret != 0:
# msg = _("Error removing comments '{0}': {1}")
# raise TemplateError(msg.format(filevar['del_comment'], err))
def prepare_template(self, def prepare_template(self,
filename: str): filename: str):
"""Prepare template source file """Prepare template source file
@ -359,12 +341,10 @@ class CreoleTemplateEngine:
log.info(_("Copy template: '{filename}' -> '{self.tmp_dir}'")) log.info(_("Copy template: '{filename}' -> '{self.tmp_dir}'"))
copy(filename, self.tmp_dir) copy(filename, self.tmp_dir)
self.patch_template(filename) self.patch_template(filename)
# self.strip_template_comment(filename)
def process(self, def process(self,
destfilename: str, destfilename: str,
filevar: Dict, filevar: Dict,
container: str,
variable: Any): variable: Any):
"""Process a cheetah template """Process a cheetah template
""" """
@ -387,51 +367,12 @@ class CreoleTemplateEngine:
with open(destfilename, 'w') as file_h: with open(destfilename, 'w') as file_h:
file_h.write(data) file_h.write(data)
def change_properties(self,
destfilename:str,
filevar: Dict):
#chowncmd = ['chown']
#chownarg = ''
chmodcmd = ['chmod']
chmodarg = ''
#if 'owner' in filevar and filevar['owner']:
# chownarg = filevar['owner']
#else:
# chownarg = 'root'
#if 'group' in filevar and filevar['group']:
# chownarg += ":" + filevar['group']
#else:
# chownarg += ':root'
if 'mode' in filevar and filevar['mode']:
chmodarg = filevar['mode']
else:
chmodarg = '0644'
#chowncmd.extend( [chownarg, destfilename] )
chmodcmd.extend([chmodarg, destfilename])
#log.info(_('Changing properties: {0}').format(' '.join(chowncmd)) )
#ret = call(chowncmd)
#if ret:
# log.error(_('Error changing properties {0}: {1}').format(ret, err) )
log.info(_('Changing properties: {0}').format(' '.join(chmodcmd)) )
ret = call(chmodcmd)
if ret:
chmod_cmd = ' '.join(chmodcmd)
log.error(_(f'Error changing properties: {chmodcmd}'))
def instance_file(self, def instance_file(self,
filevar: Dict, filevar: Dict,
container: str): systemd_rights: list) -> None:
"""Run templatisation on one file of one container """Run templatisation on one file
""" """
log.info(_("Instantiating file '{filename}'")) log.info(_("Instantiating file '{filename}'"))
container_dir = join(self.dest_dir,
container)
filenames = filevar['name'] filenames = filevar['name']
if 'variable' in filevar: if 'variable' in filevar:
variable = filevar['variable'] variable = filevar['variable']
@ -442,7 +383,7 @@ class CreoleTemplateEngine:
if variable: if variable:
variable = [variable] variable = [variable]
for idx, filename in enumerate(filenames): for idx, filename in enumerate(filenames):
destfilename = join(container_dir, destfilename = join(self.dest_dir,
filename[1:]) filename[1:])
makedirs(dirname(destfilename), exist_ok=True) makedirs(dirname(destfilename), exist_ok=True)
if variable: if variable:
@ -451,35 +392,26 @@ class CreoleTemplateEngine:
var = None var = None
self.process(destfilename, self.process(destfilename,
filevar, filevar,
container,
var) var)
self.change_properties(destfilename, systemd_rights.append(f'C {filename} {filevar["mode"]} {filevar["owner"]} {filevar["group"]} - -')
filevar) systemd_rights.append(f'z {filename} - - - - -')
async def instance_files(self, async def instance_files(self) -> None:
container=None): """Run templatisation on all files
"""Run templatisation on all files of all containers
@param container: name of a container
@type container: C{str}
""" """
for option in await self.config.option.list(type='all'): for option in await self.config.option.list(type='all'):
namespace = await option.option.name() namespace = await option.option.name()
if namespace in ['services', 'actions']: if namespace in ['services', 'actions']:
continue continue
elif namespace == 'creole': elif namespace == 'creole':
await self.load_eole_variables_creole(self.config, await self.load_eole_variables_creole(option)
option)
else: else:
await self.load_eole_variables(self.config, await self.load_eole_variables(namespace,
namespace,
option) option)
for template in listdir(self.distrib_dir): for template in listdir(self.distrib_dir):
self.prepare_template(join(self.distrib_dir, template)) self.prepare_template(join(self.distrib_dir, template))
systemd_rights = []
for service_obj in await self.config.option('services').list('all'): for service_obj in await self.config.option('services').list('all'):
current_container = await service_obj.option.doc()
if container is not None and container != current_container:
continue
for fills in await service_obj.list('all'): for fills in await service_obj.list('all'):
if await fills.option.name() == 'files': if await fills.option.name() == 'files':
for fill_obj in await fills.list('all'): for fill_obj in await fills.list('all'):
@ -490,20 +422,23 @@ class CreoleTemplateEngine:
raise FileNotFound(_(f"File {distib_file} does not exist.")) raise FileNotFound(_(f"File {distib_file} does not exist."))
if fill.get('activate', False): if fill.get('activate', False):
self.instance_file(fill, self.instance_file(fill,
current_container) systemd_rights)
else: else:
log.debug(_("Instantiation of file '{filename}' disabled")) log.debug(_("Instantiation of file '{filename}' disabled"))
with open(join(self.dest_dir, 'rougail.conf'), 'w') as fh:
fh.write('\n'.join(systemd_rights))
fh.write('\n')
async def generate(config: Config, async def generate(config: Config,
eosfunc_file: str, eosfunc_file: str,
distrib_dir: str, distrib_dir: str,
tmp_dir: str, tmp_dir: str,
dest_dir: str, dest_dir: str) -> None:
container: str=None):
engine = CreoleTemplateEngine(config, engine = CreoleTemplateEngine(config,
eosfunc_file, eosfunc_file,
distrib_dir, distrib_dir,
tmp_dir, tmp_dir,
dest_dir) dest_dir)
await engine.instance_files(container=container) await engine.instance_files()

View File

@ -1,7 +1,7 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services> <services>
<service name="tata"> <service name="tata">
</service> </service>
</services> </services>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -20,6 +20,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -20,6 +20,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,6 +17,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,6 +17,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -18,6 +18,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -20,6 +20,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,6 +17,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,6 +17,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<creole> <rougail>
<services/> <services/>
@ -18,6 +18,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,12 +17,12 @@
<constraints> <constraints>
<auto name="calc_val" target="mode_conteneur_actif"> <auto name="calc_val" target="mode_conteneur_actif">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</auto> </auto>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -22,6 +22,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -0,0 +1,22 @@
<?xml version='1.0' encoding='UTF-8'?>
<rougail>
<services/>
<variables>
<family name="general">
<variable name="mode_conteneur_actif" type="oui/non" description="Redefine description" hidden="True" multi="True">
<value>non</value>
</variable>
</family>
<separators/>
</variables>
<constraints>
</constraints>
<help/>
</rougail>
<!-- vim: ts=4 sw=4 expandtab
-->

View File

@ -0,0 +1,19 @@
<?xml version='1.0' encoding='UTF-8'?>
<creole>
<family doc="" name="creole">
<family doc="general" name="general">
<property>normal</property>
<variable doc="Redefine description" multi="True" name="mode_conteneur_actif" type="choice">
<choice type="string">oui</choice>
<choice type="string">non</choice>
<property>force_default_on_freeze</property>
<property>frozen</property>
<property>hidden</property>
<property>mandatory</property>
<property>normal</property>
<value type="string">non</value>
</variable>
</family>
<separators/>
</family>
</creole>

View File

@ -0,0 +1,22 @@
<?xml version='1.0' encoding='UTF-8'?>
<rougail>
<services/>
<variables>
<family name="general">
<variable name="mode_conteneur_actif" type="oui/non" description="Redefine description" hidden="True" submulti="True">
<value>non</value>
</variable>
</family>
<separators/>
</variables>
<constraints>
</constraints>
<help/>
</rougail>
<!-- vim: ts=4 sw=4 expandtab
-->

View File

@ -0,0 +1,19 @@
<?xml version='1.0' encoding='UTF-8'?>
<creole>
<family doc="" name="creole">
<family doc="general" name="general">
<property>normal</property>
<variable doc="Redefine description" multi="submulti" name="mode_conteneur_actif" type="choice">
<choice type="string">oui</choice>
<choice type="string">non</choice>
<property>force_default_on_freeze</property>
<property>frozen</property>
<property>hidden</property>
<property>mandatory</property>
<property>normal</property>
<value type="string">non</value>
</variable>
</family>
<separators/>
</family>
</creole>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -20,12 +20,12 @@
<constraints> <constraints>
<fill name="calc_val" target="mode_conteneur_actif"> <fill name="calc_val" target="mode_conteneur_actif">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</fill> </fill>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,12 +17,12 @@
<constraints> <constraints>
<fill name="calc_val" target="mode_conteneur_actif"> <fill name="calc_val" target="mode_conteneur_actif">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</fill> </fill>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,12 +17,12 @@
<constraints> <constraints>
<fill name="calc_val" target="mode_conteneur_actif"> <fill name="calc_val" target="mode_conteneur_actif">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</fill> </fill>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,12 +17,12 @@
<constraints> <constraints>
<fill name="calc_val" target="mode_conteneur_actif"> <fill name="calc_val" target="mode_conteneur_actif">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</fill> </fill>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -15,12 +15,12 @@
<constraints> <constraints>
<fill name="calc_val" target="mode_conteneur_actif"> <fill name="calc_val" target="mode_conteneur_actif">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</fill> </fill>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -21,6 +21,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,14 +17,14 @@
<constraints> <constraints>
<fill name="calc_val" target="mode_conteneur_actif"> <fill name="calc_val" target="mode_conteneur_actif">
<param type="eole" optional="True">mode_conteneur_actif4</param> <param type="variable" optional="True">mode_conteneur_actif4</param>
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
<param type="eole" optional="True">mode_conteneur_actif3</param> <param type="variable" optional="True">mode_conteneur_actif3</param>
</fill> </fill>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,6 +19,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,6 +19,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -22,6 +22,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -25,6 +25,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -22,6 +22,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,12 +19,12 @@
<constraints> <constraints>
<check name="valid_entier" target="int"> <check name="valid_entier" target="int">
<param name="mini">0</param> <param name="mini">0</param>
<param name="maxi" type="eole">int2</param> <param name="maxi" type="variable">int2</param>
</check> </check>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -16,16 +16,16 @@
<constraints> <constraints>
<check name="valid_differ" target="int"> <check name="valid_differ" target="int">
<param type="eole" optional="True">int2</param> <param type="variable" optional="True">int2</param>
</check> </check>
<check name="valid_differ" target="int"> <check name="valid_differ" target="int">
<param type="eole" optional="True">int3</param> <param type="variable" optional="True">int3</param>
</check> </check>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,12 +17,12 @@
<constraints> <constraints>
<check name="valid_differ" target="mode_conteneur_actif"> <check name="valid_differ" target="mode_conteneur_actif">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</check> </check>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -23,15 +23,15 @@
<constraints> <constraints>
<check name="valid_differ" target="mode_conteneur_actif3"> <check name="valid_differ" target="mode_conteneur_actif3">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</check> </check>
<check name="valid_differ" target="mode_conteneur_actif3"> <check name="valid_differ" target="mode_conteneur_actif3">
<param type="eole">mode_conteneur_actif2</param> <param type="variable">mode_conteneur_actif2</param>
</check> </check>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -14,15 +14,15 @@
<constraints> <constraints>
<check name="valid_differ" target="mode_conteneur_actif3"> <check name="valid_differ" target="mode_conteneur_actif3">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</check> </check>
<check name="valid_differ" target="mode_conteneur_actif3"> <check name="valid_differ" target="mode_conteneur_actif3">
<param type="eole">mode_conteneur_actif2</param> <param type="variable">mode_conteneur_actif2</param>
</check> </check>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -23,15 +23,15 @@
<constraints> <constraints>
<check name="valid_differ" target="mode_conteneur_actif3"> <check name="valid_differ" target="mode_conteneur_actif3">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</check> </check>
<check name="valid_differ" target="mode_conteneur_actif3"> <check name="valid_differ" target="mode_conteneur_actif3">
<param type="eole">mode_conteneur_actif2</param> <param type="variable">mode_conteneur_actif2</param>
</check> </check>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -14,15 +14,15 @@
<constraints> <constraints>
<check name="valid_differ" target="mode_conteneur_actif3"> <check name="valid_differ" target="mode_conteneur_actif3">
<param type="eole">mode_conteneur_actif1</param> <param type="variable">mode_conteneur_actif1</param>
</check> </check>
<check name="valid_differ" target="mode_conteneur_actif3"> <check name="valid_differ" target="mode_conteneur_actif3">
<param type="eole">mode_conteneur_actif2</param> <param type="variable">mode_conteneur_actif2</param>
</check> </check>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -16,12 +16,12 @@
<constraints> <constraints>
<check name="valid_ipnetmask" target="adresse_netmask_eth0" level="warning"> <check name="valid_ipnetmask" target="adresse_netmask_eth0" level="warning">
<param type="eole">adresse_ip_eth0</param> <param type="variable">adresse_ip_eth0</param>
</check> </check>
</constraints> </constraints>
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -29,6 +29,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -29,6 +29,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -34,6 +34,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -33,6 +33,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -29,6 +29,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -28,6 +28,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -31,6 +31,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -32,6 +32,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<creole> <rougail>
<variables> <variables>
<family name='general'> <family name='general'>
@ -29,6 +29,6 @@
</condition> </condition>
</constraints> </constraints>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -28,6 +28,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -21,7 +21,7 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</fill> </fill>
<fill name="calc_val" target="slave2"> <fill name="calc_val" target="slave2">
<param type="eole">slave1</param> <param type="variable">slave1</param>
</fill> </fill>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -31,4 +31,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -25,4 +25,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -25,4 +25,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<creole> <rougail>
<variables> <variables>
<family name='general'> <family name='general'>
<variable name='mode_conteneur_actif' type='oui/non' description="No change"> <variable name='mode_conteneur_actif' type='oui/non' description="No change">
@ -17,11 +17,11 @@
<param name='valeur'>valfill</param> <param name='valeur'>valfill</param>
</fill> </fill>
<fill name='calc_val' target='slave2'> <fill name='calc_val' target='slave2'>
<param type='eole'>slave1</param> <param type='variable'>slave1</param>
</fill> </fill>
<group master='master' description="other description"> <group master='master' description="other description">
<slave>slave1</slave> <slave>slave1</slave>
<slave>slave2</slave> <slave>slave2</slave>
</group> </group>
</constraints> </constraints>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -25,4 +25,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -14,4 +14,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -18,6 +18,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,7 +19,7 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</fill> </fill>
<fill name="calc_val" target="slave2"> <fill name="calc_val" target="slave2">
<param type="eole">slave1</param> <param type="variable">slave1</param>
</fill> </fill>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -29,4 +29,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,7 +19,7 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</fill> </fill>
<fill name="calc_val" target="slave2"> <fill name="calc_val" target="slave2">
<param type="eole">slave1</param> <param type="variable">slave1</param>
</fill> </fill>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -29,4 +29,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<variables> <variables>
<family name="général"> <family name="général">
@ -20,6 +20,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,7 +19,7 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</fill> </fill>
<fill name="calc_val" target="slave2"> <fill name="calc_val" target="slave2">
<param type="eole">slave1</param> <param type="variable">slave1</param>
</fill> </fill>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -29,4 +29,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -24,7 +24,7 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</fill> </fill>
<fill name="calc_val" target="slave2"> <fill name="calc_val" target="slave2">
<param type="eole">slave1</param> <param type="variable">slave1</param>
</fill> </fill>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -38,4 +38,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -21,7 +21,7 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</fill> </fill>
<fill name="calc_val" target="slave2"> <fill name="calc_val" target="slave2">
<param type="eole">slave1</param> <param type="variable">slave1</param>
</fill> </fill>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -31,4 +31,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -17,4 +17,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -20,10 +20,10 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</auto> </auto>
<auto name="calc_val" target="slave2"> <auto name="calc_val" target="slave2">
<param type="eole">slave1</param> <param type="variable">slave1</param>
</auto> </auto>
<auto name="calc_val" target="slave3"> <auto name="calc_val" target="slave3">
<param type="eole">master</param> <param type="variable">master</param>
</auto> </auto>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -34,4 +34,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,7 +19,7 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</auto> </auto>
<auto name="calc_val" target="slave2"> <auto name="calc_val" target="slave2">
<param type="eole">master</param> <param type="variable">master</param>
</auto> </auto>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -29,4 +29,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -28,4 +28,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,7 +19,7 @@
<param name="valeur">valfill</param> <param name="valeur">valfill</param>
</fill> </fill>
<fill name="calc_val" target="slave2"> <fill name="calc_val" target="slave2">
<param type="eole">slave1</param> <param type="variable">slave1</param>
</fill> </fill>
<group master="master"> <group master="master">
<slave>slave1</slave> <slave>slave1</slave>
@ -29,4 +29,4 @@
<help/> <help/>
</creole> </rougail>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -27,6 +27,6 @@
<variable name="enumvar">bla bla bla</variable> <variable name="enumvar">bla bla bla</variable>
</help> </help>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -27,6 +27,6 @@
<variable name="enumvar">bla bla bla</variable> <variable name="enumvar">bla bla bla</variable>
</help> </help>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -33,6 +33,6 @@
<variable name="enumvar">bla bla bla</variable> <variable name="enumvar">bla bla bla</variable>
</help> </help>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -21,6 +21,6 @@
<help> <help>
</help> </help>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -19,6 +19,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -20,6 +20,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
<variables> <variables>
<family name="general" mode="expert"> <family name="general" mode="expert">
@ -18,6 +18,6 @@
<param>['a','b','c']</param> <param>['a','b','c']</param>
</check> </check>
</constraints> </constraints>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -27,6 +27,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -21,6 +21,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -25,6 +25,6 @@
<variable name="enumvar">bla bla bla</variable> <variable name="enumvar">bla bla bla</variable>
</help> </help>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -27,6 +27,6 @@
<variable name="enumvar">bla bla bla</variable> <variable name="enumvar">bla bla bla</variable>
</help> </help>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -27,6 +27,6 @@
<variable name="enumvar">bla bla bla</variable> <variable name="enumvar">bla bla bla</variable>
</help> </help>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services/> <services/>
@ -20,6 +20,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services> <services>
<service name="test"> <service name="test">
@ -33,6 +33,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1 +1 @@
{"creole.general.condition": "non", "creole.general.mode_conteneur_actif": "non", "creole.general.mode_conteneur_actif2": "non", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file", "services.service0.files.file0.activate": true} {"creole.general.condition": "non", "creole.general.mode_conteneur_actif": "non", "creole.general.mode_conteneur_actif2": "non", "services.service0.files.file0.group": "root", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.mode": "0644", "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.owner": "root", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file", "services.service0.files.file0.activate": true}

View File

@ -4,19 +4,36 @@
<family name="service0" doc="test"> <family name="service0" doc="test">
<family doc="files" name="files"> <family doc="files" name="files">
<family doc="file0" name="file0"> <family doc="file0" name="file0">
<variable doc="" multi="False" name="group" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="mkdir" type="boolean"> <variable doc="" multi="False" name="mkdir" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="mode" type="string">
<property>mandatory</property>
<value>0644</value>
</variable>
<variable doc="" multi="False" name="name" type="string"> <variable doc="" multi="False" name="name" type="string">
<property>mandatory</property>
<value>/tmp/file</value> <value>/tmp/file</value>
</variable> </variable>
<variable doc="" multi="False" name="owner" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="rm" type="boolean"> <variable doc="" multi="False" name="rm" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="source" type="string"> <variable doc="" multi="False" name="source" type="string">
<property>mandatory</property>
<value>file</value> <value>file</value>
</variable> </variable>
<variable doc="" multi="False" name="activate" type="boolean"> <variable doc="" multi="False" name="activate" type="boolean">
<property>mandatory</property>
<property expected="oui" inverse="False" source="creole.general.condition" type="calculation">disabled</property> <property expected="oui" inverse="False" source="creole.general.condition" type="calculation">disabled</property>
<value>True</value> <value>True</value>
</variable> </variable>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services> <services>
<service name="test"> <service name="test">
@ -33,6 +33,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1 +1 @@
{"creole.general.condition": "oui", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file"} {"creole.general.condition": "oui", "services.service0.files.file0.group": "root", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.mode": "0644", "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.owner": "root", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file"}

View File

@ -4,19 +4,36 @@
<family name="service0" doc="test"> <family name="service0" doc="test">
<family doc="files" name="files"> <family doc="files" name="files">
<family doc="file0" name="file0"> <family doc="file0" name="file0">
<variable doc="" multi="False" name="group" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="mkdir" type="boolean"> <variable doc="" multi="False" name="mkdir" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="mode" type="string">
<property>mandatory</property>
<value>0644</value>
</variable>
<variable doc="" multi="False" name="name" type="string"> <variable doc="" multi="False" name="name" type="string">
<property>mandatory</property>
<value>/tmp/file</value> <value>/tmp/file</value>
</variable> </variable>
<variable doc="" multi="False" name="owner" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="rm" type="boolean"> <variable doc="" multi="False" name="rm" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="source" type="string"> <variable doc="" multi="False" name="source" type="string">
<property>mandatory</property>
<value>file</value> <value>file</value>
</variable> </variable>
<variable doc="" multi="False" name="activate" type="boolean"> <variable doc="" multi="False" name="activate" type="boolean">
<property>mandatory</property>
<property expected="oui" inverse="False" source="creole.general.condition" type="calculation">disabled</property> <property expected="oui" inverse="False" source="creole.general.condition" type="calculation">disabled</property>
<value>True</value> <value>True</value>
</variable> </variable>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services> <services>
<service name="test"> <service name="test">
@ -34,6 +34,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1 +1 @@
{"creole.general.condition": "non", "creole.general.mode_conteneur_actif": "non", "creole.general.mode_conteneur_actif2": "non", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.name": "/tmp/file1", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file1", "services.service0.files.file0.activate": true, "services.service0.files.file1.mkdir": false, "services.service0.files.file1.name": "/tmp/file2", "services.service0.files.file1.rm": false, "services.service0.files.file1.source": "file2", "services.service0.files.file1.activate": true} {"creole.general.condition": "non", "creole.general.mode_conteneur_actif": "non", "creole.general.mode_conteneur_actif2": "non", "services.service0.files.file0.group": "root", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.mode": "0644", "services.service0.files.file0.name": "/tmp/file1", "services.service0.files.file0.owner": "root", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file1", "services.service0.files.file0.activate": true, "services.service0.files.file1.group": "root", "services.service0.files.file1.mkdir": false, "services.service0.files.file1.mode": "0644", "services.service0.files.file1.name": "/tmp/file2", "services.service0.files.file1.owner": "root", "services.service0.files.file1.rm": false, "services.service0.files.file1.source": "file2", "services.service0.files.file1.activate": true}

View File

@ -4,37 +4,71 @@
<family name="service0" doc="test"> <family name="service0" doc="test">
<family doc="files" name="files"> <family doc="files" name="files">
<family doc="file0" name="file0"> <family doc="file0" name="file0">
<variable doc="" multi="False" name="group" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="mkdir" type="boolean"> <variable doc="" multi="False" name="mkdir" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="mode" type="string">
<property>mandatory</property>
<value>0644</value>
</variable>
<variable doc="" multi="False" name="name" type="string"> <variable doc="" multi="False" name="name" type="string">
<property>mandatory</property>
<value>/tmp/file1</value> <value>/tmp/file1</value>
</variable> </variable>
<variable doc="" multi="False" name="owner" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="rm" type="boolean"> <variable doc="" multi="False" name="rm" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="source" type="string"> <variable doc="" multi="False" name="source" type="string">
<property>mandatory</property>
<value>file1</value> <value>file1</value>
</variable> </variable>
<variable doc="" multi="False" name="activate" type="boolean"> <variable doc="" multi="False" name="activate" type="boolean">
<property>mandatory</property>
<property expected="oui" inverse="False" source="creole.general.condition" type="calculation">disabled</property> <property expected="oui" inverse="False" source="creole.general.condition" type="calculation">disabled</property>
<value>True</value> <value>True</value>
</variable> </variable>
</family> </family>
<family doc="file1" name="file1"> <family doc="file1" name="file1">
<variable doc="" multi="False" name="group" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="mkdir" type="boolean"> <variable doc="" multi="False" name="mkdir" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="mode" type="string">
<property>mandatory</property>
<value>0644</value>
</variable>
<variable doc="" multi="False" name="name" type="string"> <variable doc="" multi="False" name="name" type="string">
<property>mandatory</property>
<value>/tmp/file2</value> <value>/tmp/file2</value>
</variable> </variable>
<variable doc="" multi="False" name="owner" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="rm" type="boolean"> <variable doc="" multi="False" name="rm" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="source" type="string"> <variable doc="" multi="False" name="source" type="string">
<property>mandatory</property>
<value>file2</value> <value>file2</value>
</variable> </variable>
<variable doc="" multi="False" name="activate" type="boolean"> <variable doc="" multi="False" name="activate" type="boolean">
<property>mandatory</property>
<property expected="oui" inverse="False" source="creole.general.condition" type="calculation">disabled</property> <property expected="oui" inverse="False" source="creole.general.condition" type="calculation">disabled</property>
<value>True</value> <value>True</value>
</variable> </variable>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services> <services>
<service name="test"> <service name="test">
@ -31,6 +31,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1 +1 @@
{"creole.general.condition": "non", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file"} {"creole.general.condition": "non", "services.service0.files.file0.group": "root", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.mode": "0644", "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.owner": "root", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file"}

View File

@ -4,20 +4,37 @@
<family name="service0" doc="test"> <family name="service0" doc="test">
<family doc="files" name="files"> <family doc="files" name="files">
<family doc="file0" name="file0"> <family doc="file0" name="file0">
<variable doc="" multi="False" name="group" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="mkdir" type="boolean"> <variable doc="" multi="False" name="mkdir" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="mode" type="string">
<property>mandatory</property>
<value>0644</value>
</variable>
<variable doc="" multi="False" name="name" type="string"> <variable doc="" multi="False" name="name" type="string">
<property>mandatory</property>
<value>/tmp/file</value> <value>/tmp/file</value>
</variable> </variable>
<variable doc="" multi="False" name="owner" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="rm" type="boolean"> <variable doc="" multi="False" name="rm" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="source" type="string"> <variable doc="" multi="False" name="source" type="string">
<property>mandatory</property>
<value>file</value> <value>file</value>
</variable> </variable>
<variable doc="" multi="False" name="activate" type="boolean"> <variable doc="" multi="False" name="activate" type="boolean">
<property>disabled</property> <property>disabled</property>
<property>mandatory</property>
<value>True</value> <value>True</value>
</variable> </variable>
</family> </family>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services> <services>
<service name="test"> <service name="test">
@ -32,6 +32,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1 +1 @@
{"creole.general.condition": "non", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file"} {"creole.general.condition": "non", "services.service0.files.file0.group": "root", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.mode": "0644", "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.owner": "root", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file"}

View File

@ -4,20 +4,37 @@
<family name="service0" doc="test"> <family name="service0" doc="test">
<family doc="files" name="files"> <family doc="files" name="files">
<family doc="file0" name="file0"> <family doc="file0" name="file0">
<variable doc="" multi="False" name="group" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="mkdir" type="boolean"> <variable doc="" multi="False" name="mkdir" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="mode" type="string">
<property>mandatory</property>
<value>0644</value>
</variable>
<variable doc="" multi="False" name="name" type="string"> <variable doc="" multi="False" name="name" type="string">
<property>mandatory</property>
<value>/tmp/file</value> <value>/tmp/file</value>
</variable> </variable>
<variable doc="" multi="False" name="owner" type="string">
<property>mandatory</property>
<value>root</value>
</variable>
<variable doc="" multi="False" name="rm" type="boolean"> <variable doc="" multi="False" name="rm" type="boolean">
<property>mandatory</property>
<value>False</value> <value>False</value>
</variable> </variable>
<variable doc="" multi="False" name="source" type="string"> <variable doc="" multi="False" name="source" type="string">
<property>mandatory</property>
<value>file</value> <value>file</value>
</variable> </variable>
<variable doc="" multi="False" name="activate" type="boolean"> <variable doc="" multi="False" name="activate" type="boolean">
<property>disabled</property> <property>disabled</property>
<property>mandatory</property>
<value>True</value> <value>True</value>
</variable> </variable>
</family> </family>

View File

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='UTF-8'?> <?xml version='1.0' encoding='UTF-8'?>
<creole> <rougail>
<services> <services>
<service name="test"> <service name="test">
@ -35,6 +35,6 @@
<help/> <help/>
</creole> </rougail>
<!-- vim: ts=4 sw=4 expandtab <!-- vim: ts=4 sw=4 expandtab
--> -->

View File

@ -1 +1 @@
{"creole.general.condition": "non", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file"} {"creole.general.condition": "non", "services.service0.files.file0.group": "root", "services.service0.files.file0.mkdir": false, "services.service0.files.file0.mode": "0644", "services.service0.files.file0.name": "/tmp/file", "services.service0.files.file0.owner": "root", "services.service0.files.file0.rm": false, "services.service0.files.file0.source": "file"}

Some files were not shown because too many files have changed in this diff Show More