Hi!

There's already a feature present, it is https://fate.novell.com/307388:

Citing from feature description: "Ideally, there should only be a single 
config dir (or file ?) covering all vendor customization.
All customization (the config file, branding images, web style css file(s), 
etc.) should be contained in a single -branding package."

As I'm looking into services module, which should offer Start/Stop options to 
vendor specific services (fate 306696), I also need some way to provide 
vendor specific data. Here, the data are: the list of services to show (a 
must) and optionally custom descriptions and paths to start/stop scripts to 
such services.

So far, I'm using yml file (after Klaus' recommendation) as it is easy to 
parse and human readable. See attached examples: one is for list of maps 
(slightly better readable I assume), the second for map of maps (faster 
access). The file is currently expected under /etc/YaST2 directory.

Technically, config file is parsed from YaPI which is called from 
rest-service, so it is not bound to webYaST usage and theoretically could be 
used together with YaPI from perl scripts.

Comments, ideas?

I have one to the feature description above: I'd rather vote for more config 
files (under same directory) over just one-for-all, as it needs to be parsed 
for each YaPI call.

Jiri

-- 
Jiri Suchomel

SUSE LINUX, s.r.o.                            e-mail: [email protected]
Lihovarská 1060/12                            tel: +420 284 028 960
190 00 Praha 9, Czech Republic                http://www.suse.cz
# The list of services that could be operated by webYaST services module.
# Add only name of service if there is /etc/init.d/<service-name> script 
available.
# Otherwise, provide also service description and paths to start, stop and 
status scripts.

services:
  cron:
    name: cron

  dbus:
    name: dbus

  beagle:
    name: beagle
    description: Desktop Search Application
    start: "/usr/bin/beagled"
    stop: "/usr/bin/beagle-shutdown"
    status: "/usr/bin/beagle-ping"

  collectd:
    name: collectd
    description: Statistics Collection Daemon for filling RRD Files
    start: "/usr/sbin/rccollectd start"
    stop: "/usr/sbin/rccollectd stop"
    status: "/usr/sbin/rccollectd status"
# The list of services that could be operated by webYaST services module.
# Add only name of service if there is /etc/init.d/<service-name> script 
available.
# Otherwise, provide also service description and paths to start, stop and 
status scripts.

services:
    - name: cron

    - name: dbus

    - name: beagle
      description: Desktop Search Application
      start: "/usr/bin/beagled"
      stop: "/usr/bin/beagle-shutdown"
      status: "/usr/bin/beagle-ping"

    - name: collectd
      description: Statistics Collection Daemon for filling RRD Files
      start: "/usr/sbin/rccollectd start"
      stop: "/usr/sbin/rccollectd stop"
      status: "/usr/sbin/rccollectd status"

Reply via email to