mirror of
https://github.com/ceph/ceph
synced 2024-12-18 01:16:55 +00:00
cc10988850
To deploy ceph-rest-api within a WSGI server (apache/mod_wsgi, nginx/uwsgi, etc.), there needs to be an importable (.py) module that performs all init/config when imported. ceph-rest-api was close, but it needs to be named properly, and there's no argument passing, so it needs to get args from a fixed file or the env. Separate most of ceph-rest-api into pybind/ceph_rest_api.py, and make its arguments come from the environment, and init errors be ImportError exceptions. Recase ceph-rest-api as a thin layer that does the usual setup and arg parsing, and then sets args into the environment and imports ceph_rest_api.py, catching exceptions and reporting errors. This allows standalone execution as usual. ceph-rest-api grabs a few module globals (addr/port and the flask.app) to use after it imports. Accept cluster name, and do the ceph.conf search using cluster name in the appropriate places in the searched-for files. Also ceph_rest_api.py gets a little cleanup (fewer global variables, cleaner conf file search algorithm, better error reporting on conf load) Also: doc updates, packaging updates to include ceph_rest_api.py Signed-off-by: Dan Mick <dan.mick@inktank.com> |
||
---|---|---|
.. | ||
ceph-authtool.rst | ||
ceph-clsinfo.rst | ||
ceph-conf.rst | ||
ceph-debugpack.rst | ||
ceph-dencoder.rst | ||
ceph-fuse.rst | ||
ceph-mds.rst | ||
ceph-mon.rst | ||
ceph-osd.rst | ||
ceph-rbdnamer.rst | ||
ceph-rest-api.rst | ||
ceph-run.rst | ||
ceph-syn.rst | ||
ceph.rst | ||
cephfs.rst | ||
crushtool.rst | ||
librados-config.rst | ||
mkcephfs.rst | ||
monmaptool.rst | ||
mount.ceph.rst | ||
osdmaptool.rst | ||
rados.rst | ||
radosgw-admin.rst | ||
radosgw.rst | ||
rbd-fuse.rst | ||
rbd.rst |