1. Configuration File Workings

Coriolis do not have any dedicated file format for it’s configuration files. Instead, configuration files are Python scripts that are expected to provides a set of variables with specific contents. For example, .coriolis2/techno.py must provide a technology variable and optionaly a NdaDirectory variable. So, it’s simplest form is:

technology = '45/freepdk_45'

A more complex case could be:

Ndadirectory = '/home/crypted'
technology   = '45/freepdk_45'

And lastly, taking full advantage of the Python langage:

import os.path
import socket

hostname = socket.gethostname()
if hostname.startswith('local-computer'):
  NdaDirectory = '/home/crypted'
  if not os.path.isdir(NdaDirectory):
    print '[ERROR] You forgot to mount the NDA encrypted directory, stupid!'
else:
  NdaDirectory = '/network/techno/'

technology = '45/freepdk_45'

In this script, we choose the value of NdaDirectory according the computer’s hostname and when using the local filesystem we check if the directory exist.

A second kind of example is .coriolis2/settings.py. It must provides a variable parametersTable which is tuple of variable settings. Each element of the tuple is itself a tuple of three elements (variable_name, type, value)

parametersTable = \
    ( ('misc.catchCore'    , TypeBool, False   )
    , ('misc.logMode'      , TypeBool, False   )
    , ('misc.verboseLevel1', TypeBool, True    )
    , ('misc.verboseLevel2', TypeBool, True    )
    )

2. Directory Tree Structure

Depending if Coriolis is installed in the system or in a separate tree, the configuration can be rooted in :

/etc/coriolis2                # System install.
<CORIOLIS_TOP>/etc/coriolis2  # Separate tree install.