From 07dee3430510d4864e6f8497f31458f756052b14 Mon Sep 17 00:00:00 2001 From: Jan Dittberner Date: Tue, 3 Mar 2020 15:24:11 +0100 Subject: [PATCH] Update documentation - use alabaster theme - update changelog - use version number from code module --- docs/changelog.rst | 5 +++++ docs/code.rst | 23 ++++++++------------- docs/conf.py | 51 +++++++++++++++++----------------------------- docs/deploy.rst | 2 +- docs/install.rst | 3 ++- 5 files changed, 36 insertions(+), 48 deletions(-) diff --git a/docs/changelog.rst b/docs/changelog.rst index 29e6b9a..3265a4a 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -1,6 +1,11 @@ Changelog ========= +* :support:`-` add Docker setup for lightweight local testing +* :support:`-` restructure code to have celery in the webtasks module and drop + the gvaldap module +* :support:`-` update documentation to alabaster theme + * :release:`0.1.8 <2020-03-02>` * :bug:`-` salt automation was broken due to changed paths and missing Jinja 2 dependency diff --git a/docs/code.rst b/docs/code.rst index a379324..eaa03ef 100644 --- a/docs/code.rst +++ b/docs/code.rst @@ -7,30 +7,25 @@ gvaweb is implemented as `Celery`_ app. .. _Celery: http://www.celeryproject.org/ -The project module :py:mod:`gvaweb` -=================================== +The module :py:mod:`webtasks` +============================= -.. automodule:: gvaweb +.. automodule:: webtasks -:py:mod:`celery ` --------------------------------- +:py:mod:`celery ` +---------------------------------- -.. automodule:: gvaweb.celery +.. automodule:: webtasks.celery :members: -:py:mod:`settings ` ------------------------------------- +:py:mod:`settings ` +-------------------------------------- -.. automodule:: gvaweb.settings +.. automodule:: webtasks.settings -:py:mod:`webtasks` app -====================== - -.. automodule:: webtasks - :py:mod:`tasks ` -------------------------------- diff --git a/docs/conf.py b/docs/conf.py index 9457666..72c23e8 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,10 +1,10 @@ # -*- coding: utf-8 -*- +# pymode:lint_ignore=E501 # # gvaweb documentation build configuration file, created by # sphinx-quickstart on Mon Jan 26 15:51:21 2015. # -# This file is execfile()d with the current directory set to its -# containing dir. +# This file is execfile()d with the current directory set to its containing dir. # # Note that not all possible configuration values are present in this # autogenerated file. @@ -30,18 +30,17 @@ os.environ['GVAWEB_WWWUSER_MOUNT'] = '/srv/wwwfiles' # If your documentation needs a minimal Sphinx version, state it here. #needs_sphinx = '1.0' -# Add any Sphinx extension module names here, as strings. They can be -# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom -# ones. +# Add any Sphinx extension module names here, as strings. They can be extensions +# coming with Sphinx (named 'sphinx.ext.*') or your custom ones. extensions = ['releases', 'sphinx.ext.autodoc', 'celery.contrib.sphinx'] +# configuration for releases extension +releases_issue_uri = 'https://git.dittberner.info/gnuviech/gvaweb/issues/%s' +releases_release_uri = 'https://git.dittberner.info/gnuviech/gvaweb/src/tag/%s' + # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] -releases_issue_uri = 'https://git.dittberner.info/gnuviech/gvaweb/issues/%s' - -releases_release_uri = 'https://git.dittberner.info/gnuviech/gvaweb/src/tag/%s' - # The suffix of source filenames. source_suffix = '.rst' @@ -59,10 +58,11 @@ copyright = u'2015-2020, Jan Dittberner' # |version| and |release|, also used in various other places throughout the # built documents. # -# The short X.Y version. -version = '0.1' # The full version, including alpha/beta/rc tags. -release = '0.1.8' +from webtasks import __version__ as release + +# The short X.Y version. +version = ".".join(release.split('.')[:2]) # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. @@ -78,8 +78,7 @@ release = '0.1.8' # directories to ignore when looking for source files. exclude_patterns = ['_build'] -# The reST default role (used for this markup: `text`) to use for all -# documents. +# The reST default role (used for this markup: `text`) to use for all documents. #default_role = None # If true, '()' will be appended to :func: etc. cross-reference text. @@ -99,15 +98,12 @@ pygments_style = 'sphinx' # A list of ignored prefixes for module index sorting. #modindex_common_prefix = [] -# If true, keep warnings as "system message" paragraphs in the built documents. -#keep_warnings = False - -# -- Options for HTML output ---------------------------------------------- +# -- Options for HTML output --------------------------------------------------- # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. -html_theme = 'default' +html_theme = 'alabaster' # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the @@ -138,11 +134,6 @@ html_theme = 'default' # so a file named "default.css" will overwrite the builtin "default.css". html_static_path = ['_static'] -# Add any extra paths that contain custom files (such as robots.txt or -# .htaccess) here, relative to this directory. These files are copied -# directly to the root of the documentation. -#html_extra_path = [] - # If not '', a 'Last updated on:' timestamp is inserted at every page bottom, # using the given strftime format. #html_last_updated_fmt = '%b %d, %Y' @@ -188,7 +179,7 @@ html_static_path = ['_static'] htmlhelp_basename = 'gvawebdoc' -# -- Options for LaTeX output --------------------------------------------- +# -- Options for LaTeX output -------------------------------------------------- latex_elements = { # The paper size ('letterpaper' or 'a4paper'). @@ -202,8 +193,7 @@ latex_elements = { } # Grouping the document tree into LaTeX files. List of tuples -# (source start file, target name, title, -# author, documentclass [howto, manual, or own class]). +# (source start file, target name, title, author, documentclass [howto/manual]). latex_documents = [ ('index', 'gvaweb.tex', u'gvaweb Documentation', u'Jan Dittberner', 'manual'), @@ -230,7 +220,7 @@ latex_documents = [ #latex_domain_indices = True -# -- Options for manual page output --------------------------------------- +# -- Options for manual page output -------------------------------------------- # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). @@ -243,7 +233,7 @@ man_pages = [ #man_show_urls = False -# -- Options for Texinfo output ------------------------------------------- +# -- Options for Texinfo output ------------------------------------------------ # Grouping the document tree into Texinfo files. List of tuples # (source start file, target name, title, author, @@ -262,6 +252,3 @@ texinfo_documents = [ # How to display URL addresses: 'footnote', 'no', or 'inline'. #texinfo_show_urls = 'footnote' - -# If true, do not generate a @detailmenu in the "Top" node's menu. -#texinfo_no_detailmenu = False diff --git a/docs/deploy.rst b/docs/deploy.rst index 11ceb7e..1c70387 100644 --- a/docs/deploy.rst +++ b/docs/deploy.rst @@ -7,4 +7,4 @@ of the following steps: * installation of native dependencies * setup of a virtualenv * installation of gvaweb production dependencies inside the virtualenv -* setup of celery worker under control of supervisord +* setup of celery worker under control of systemd diff --git a/docs/install.rst b/docs/install.rst index b7d9eec..2501a69 100644 --- a/docs/install.rst +++ b/docs/install.rst @@ -30,6 +30,7 @@ into the gvaweb directory and run the celery worker with: .. code-block:: sh - $ pipenv run celery -A gvaweb worker -Q web -l info + $ cd gvaweb + $ pipenv run celery -A webtasks worker -Q web -l info .. _Celery: http://www.celeryproject.org/