Changes between Version 2 and Version 3 of Bcfg2FS


Ignore:
Timestamp:
06/14/10 08:22:07 (12 years ago)
Author:
fabaff
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Bcfg2FS

    v2 v3  
    55`bcfg2-admin bundle list-xml` and `bcfg2-admin bundle show` only provide a simple and limited interface to the content of XML bundle files. As mentioned in ticket #638 the usage of a Fuse filesystem may be more intuitive than `bcfg2-admin`/`bcfg2-info` for some cases. 
    66 
    7 This page is the place for the documentation of the Bcfg2FS development.  Maybe this page will become a tutorial as well. 
     7This page is the place for the documentation of the Bcfg2FS development. Maybe this page will become a tutorial as well. 
    88 
    99== Requirements == 
     
    1212 * a mount point (e.g. in `/tmp`) 
    1313 
     14== Design == 
     15 
     16The start will be with the bundles (perhaps the new part can be called `bcfg2-admin bundle browse`). Bundles are a bit different than the other XML files like client.xml or group.xml because every bundle has its own XML file.   
     17 
     18All bundles are store in the `/var/lib/bcfg2/Bundler/` directory. 
     19 
     20 * XML files : `/var/lib/bcfg2/Bundler/*.xml` 
     21 * gensh files: `/var/lib/bcfg2/Bundler/*.genshi` 
     22 
     23A simple bundle file can look like this : 
     24{{{ 
     25#!text/xml 
     26<Bundle name='motd' version='2.0'> 
     27  <ConfigFile name='/etc/motd' /> 
     28</Bundle> 
     29}}} 
     30 
     31There are other [wiki:WritingSpecification#ConfigurationEntityTypes configuration entries] available.  
     32 
     33== Implementation == 
     34 
     35Basically a FUSE file system needs of have three functions. 
     36 
     37 * '''init''' - Starts the file system and grabs the file in the `Bundler/` directory 
     38 * '''getattr''' - Passes back the attributes of a file (at the moment not needed) 
     39 * '''readdir''' - Is needed to use `ls` 
     40 
     41== Usage == 
     42 
     43You need to make a directory with `mkdir [mountpoint]` first.   
     44 
     45{{{ 
     46$ python bcfg2fs.py [mountpoint] 
     47}}} 
     48 
     49Now you can change to the FUSE file system. 
     50 
     51{{{ 
     52$ cd [mountpoint] 
     53}}} 
     54 
     55Use `ls` to browse the directory. 
     56 
     57{{{ 
     58$ ls 
     59}}} 
     60 
     61When you are done, unmount the FUSE directory. 
     62 
     63{{{ 
     64fusemount -u [mountpoint] 
     65}}} 
     66 
     67 
    1468== Status == 
    1569 
    1670 * 2010-06-14 - The first step is done. The creation of a directory structure of available bundles is working. 
     71 
     72== !ToDo == 
     73 
     74 * Make the source available 
     75 * Implement all parts of `bcfg2-admin`  
     76 * Start with documentation 
    1777 
    1878== More information ==