Skip to content

Commit

Permalink
indent code block
Browse files Browse the repository at this point in the history
  • Loading branch information
DmitryLitvintsev committed Nov 8, 2023
1 parent a815ccb commit 6762eb6
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 34 deletions.
2 changes: 1 addition & 1 deletion docs/enstore2cta_config.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ Configuration

Script expects configuration file ``enstore2cta.yaml`` in the current directory or pointed to by environment variable ``MIGRATION_CONFIG``. The yaml file has to have "0600" permission bits and has to have the following parameters defned:

.. include:: ../etc/enstore2cta.yaml
.. literalinclude:: ../etc/enstore2cta.yaml
66 changes: 33 additions & 33 deletions docs/enstore2cta_script.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,42 +10,42 @@ Script works both with python2 and python3 and requires ``psycopg2`` module be i
Invocation
----------
To run the script a config file ``enstore2cta.yaml`` *must* exist in
the current directory or be pointed at by MIGRATION_CONFIG environment variable.
Look for example in enstore2cta/etc. It must have "0600" permission
the current directory or be pointed at by ``MIGRATION_CONFIG`` environment variable.
Look for example in ``enstore2cta/etc``. It must have "0600" permission (to protect database passwords if any).

::

$ python enstore2cta.py
usage: enstore2cta.py [-h] [--label LABEL] [--all] [--skip_locations] [--add]
[--storage_class STORAGE_CLASS] [--vo VO]
[--cpu_count CPU_COUNT]

This script converts Enstore metadata to CTA metadata. It looks for YAML
configuration file pointed to by MIGRATION_CONFIG environment variable or, if
it is not defined, it looks for file enstore2cta.yaml in current directory.
Script will quit if configuration YAML is not found.

optional arguments:
-h, --help show this help message and exit
--label LABEL comma separated list of labels (default: None)
--all do all labels (default: False)
--skip_locations skip filling chimera locations (good for testing)
(default: False)
--add add volume(s) to existing system, do not create vos,
pools, archive_routes etc. These need to pre-exist in
CTA db (default: False)
--storage_class STORAGE_CLASS
Add storage class corresponding to volume. Needed when
adding single volume to existing system using --add
option (default: None)
--vo VO vo corresponding to storage_class. Needed when adding
single volume to existing system using --add option
(default: None)
--cpu_count CPU_COUNT
override cpu count - number of simulateously processed
labels (default: 8)
single volume to existing system using --add option
```
$ python enstore2cta.py
usage: enstore2cta.py [-h] [--label LABEL] [--all] [--skip_locations] [--add]
[--storage_class STORAGE_CLASS] [--vo VO]
[--cpu_count CPU_COUNT]

This script converts Enstore metadata to CTA metadata. It looks for YAML
configuration file pointed to by MIGRATION_CONFIG environment variable or, if
it is not defined, it looks for file enstore2cta.yaml in current directory.
Script will quit if configuration YAML is not found.

optional arguments:
-h, --help show this help message and exit
--label LABEL comma separated list of labels (default: None)
--all do all labels (default: False)
--skip_locations skip filling chimera locations (good for testing)
(default: False)
--add add volume(s) to existing system, do not create vos,
pools, archive_routes etc. These need to pre-exist in
CTA db (default: False)
--storage_class STORAGE_CLASS
Add storage class corresponding to volume. Needed when
adding single volume to existing system using --add
option (default: None)
--vo VO vo corresponding to storage_class. Needed when adding
single volume to existing system using --add option
(default: None)
--cpu_count CPU_COUNT
override cpu count - number of simulateously processed
labels (default: 8)
single volume to existing system using --add option


(default cpu_count is equal to ``multiprocessing.cpu_count()``)

Expand Down

0 comments on commit 6762eb6

Please sign in to comment.