Revision 7536c9bf docs/setup.rst

b/docs/setup.rst
16 16
-----------------
17 17

  
18 18
* ansicolors
19
    * Make command line / console user interface responses pretier with text formating (colors, bold, etc.)
19
    * Make command line / console user interface responses prettier with text formating (colors, bold, etc.)
20 20
    * Can be switched on/off in kamaki configuration file: colors=on/off
21 21
    * Installation: pip install ansicolors
22 22

  
......
30 30
Configuration options
31 31
---------------------
32 32

  
33
Kamaki comes with preset default values to all configuration options. All vital configurion options are set to use the okeanos.grnet.gr cloud services. User information is not included and should be provided either through the kamaki config command or by editing the configuration file.
33
Kamaki comes with preset default values to all configuration options. All vital configuration options are set to use the okeanos.grnet.gr cloud services. User information is not included and should be provided either through the kamaki config command or by editing the configuration file.
34 34

  
35 35
Kamaki configuration options are vital for correct Kamaki behavior. An incorrect option may render some command groups dysfunctional. There are two ways of managing configuration options: edit the config file or use the kamaki config command.
36 36

  
......
39 39

  
40 40
Kamaki setups are stored in configuration files. By default, a Kamaki installation stores options in *.kamakirc* file located at the user home directory.
41 41

  
42
If a user needs to switch between different setups, Kamaki can explicitely load configuration files with the --config option:
42
If a user needs to switch between different setups, Kamaki can explicitly load configuration files with the --config option:
43 43

  
44 44
*kamaki --config <custom_config_file_path> [other options]*
45 45

  
......
48 48
Modifying options at runtime
49 49
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
50 50

  
51
All kamaki commands can be used with the -o option in order to overide configuration options at runtime. For example:
51
All kamaki commands can be used with the -o option in order to override configuration options at runtime. For example::
52 52

  
53
*kamaki store list -o global.account=anotheraccount -o global.token=aT0k3n==*
53
    kamaki store list -o global.account=anotheraccount -o global.token=aT0k3n==
54 54

  
55 55
will invoke *kamaki store list* with the specified options, but the initial global.account and global.token values will be restored to initial values afterwards.
56 56

  
......
78 78

  
79 79
The configuration file is a simple text file that can be created by the user.
80 80

  
81
A simple way to create the configuration file is to set a configuration option using the kamaki config command. For example:
81
A simple way to create the configuration file is to set a configuration option using the kamaki config command. For example::
82 82

  
83
*kamaki config set account myusername@mydomain.com*
83
    kamaki config set account myusername@mydomain.com
84 84

  
85 85
In the above example, if the kamaki configuration file does not exist, it will be created with all the default values plus the *global.account* option set to *myusername@mydomain.com* value.
86 86

  
87
The configuration file is formatted so that it can be parsed by the python ConfigParser module. It consists of command sections that are denoted with brackets. Every section contains variables with values. For example:
87
The configuration file is formatted so that it can be parsed by the python ConfigParser module. It consists of command sections that are denoted with brackets. Every section contains variables with values. For example::
88 88

  
89
*[store]*
90
*url=https://okeanos.grnet.gr/pithos*
91
*account=myaccount@mydomain.com*
89
    [store]
90
    url=https://okeanos.grnet.gr/pithos
91
    account=myaccount@mydomain.com
92 92

  
93 93
two configuration options are created: *store.url* and *store.account*. These values will be loaded at every future kamaki execution.
94 94

  
95 95
Available options
96 96
^^^^^^^^^^^^^^^^^
97 97

  
98
The [global] group is treated by kamaki as a generic group for arbitrary options, and it is used as a supergroup for vital Kamaki options, namely account, token, url, cli. This feature does not work for types of configuration options. For example if global.account option is set and store.account option is not set, store services will use the global.account option instead. In case of conflict, the most specific options override the global ones.
98
The [global] group is treated by kamaki as a generic group for arbitrary options, and it is used as a super-group for vital Kamaki options, namely account, token, url, cli. This feature does not work for types of configuration options. For example if global.account option is set and store.account option is not set, store services will use the global.account option instead. In case of conflict, the most specific options override the global ones.
99 99

  
100 100
* global.colors <on|off>
101
    enable/disable colors in command line based uis. Requires ansicolors, otherwise it is ignored
101
    enable / disable colors in command line based uis. Requires ansicolors, otherwise it is ignored
102 102

  
103 103
* global.account <account name>
104 104
    the username or user email that is user to connect to the cloud service. It can be omitted if provided as a service-specific option
......
139 139
    a special package that is used to load astakos-related commands to kamaki UIs. Don't touch this unless you know what you are doing.
140 140

  
141 141
* history.file <history file path>
142
    the path of a simple file for inter-session kamaki history. Make sure kamaki is executed in a context where this file is accessible for reading and writting. Kamaki automatically creates the file if it doesn't exist
142
    the path of a simple file for inter-session kamaki history. Make sure kamaki is executed in a context where this file is accessible for reading and writing. Kamaki automatically creates the file if it doesn't exist
143 143

  
144 144
Hidden features
145 145
^^^^^^^^^^^^^^^
......
149 149
[test]
150 150
cli=test_cli
151 151

  
152
After that, users can run "kamaki test" commands to unittest the prepackaged client APIs. Unittests are still experimental and there is a high probability of false alarms due to some of the expected values being hard-coded in the testing code.
152
After that, users can run "kamaki test" commands to unit-test the prepackaged client APIs. Unit-tests are still experimental and there is a high probability of false alarms due to some of the expected values being hard-coded in the testing code.

Also available in: Unified diff