diff --git a/docs/Makefile b/docs/Makefile index 584b60678..bc4e021cd 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -11,11 +11,24 @@ BUILDDIR = build # Put it first so that "make" without argument is like "make help". help: @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) + @echo -e " doc8 doc8 linter" + @echo -e " lint All documentation linters (including linkcheck)" + @echo -e " rstcheck rstcheck linter" -.PHONY: help Makefile server +.PHONY: doc8 help lint Makefile rstcheck server + +doc8: + doc8 --ignore D001 . + +# Documentation linters +lint: doc8 linkcheck rstcheck + +rstcheck: + -rstcheck --recursive --warn-unknown-settings . # Catch-all target: route all unknown targets to Sphinx using the new # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). +# Includes linkcheck %: Makefile @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/docs/requirements.txt b/docs/requirements.txt index 584d90c17..b76ba7093 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -1,4 +1,6 @@ +doc8 pbr +rstcheck >= 6 six sphinx sphinx_ansible_theme diff --git a/docs/source/receptorctl/receptorctl_index.rst b/docs/source/receptorctl/receptorctl_index.rst index 693858db5..24c3d397b 100644 --- a/docs/source/receptorctl/receptorctl_index.rst +++ b/docs/source/receptorctl/receptorctl_index.rst @@ -15,4 +15,5 @@ The Receptor client, ``receptorctl``, provides a command line interface for inte receptorctl_status receptorctl_traceroute receptorctl_version + receptorctl_work_cancel receptorctl_work_list diff --git a/docs/source/receptorctl/receptorctl_work_cancel.rst b/docs/source/receptorctl/receptorctl_work_cancel.rst new file mode 100644 index 000000000..ab811b6ad --- /dev/null +++ b/docs/source/receptorctl/receptorctl_work_cancel.rst @@ -0,0 +1,26 @@ +----------- +work cancel +----------- + +.. contents:: + :local: + +``receptorctl work cancel`` terminates one or more units of work. + +Command syntax: ``receptorctl --socket= work cancel <> [...]`` + +``socket_path`` is the control socket address for the Receptor connection. + The default is ``unix:`` for a Unix socket. + Use ``tcp://`` for a TCP socket. + The corresponding environment variable is ``RECEPTORCTL_SOCKET``. + +.. code-block:: text + + ss --listening --processes --unix 'src = unix:' + Netid State Recv-Q Send-Q Local Address:Port Peer Address:Port Process + u_str LISTEN 0 4096 /tmp/local.sock 38130170 * 0 users:(("receptor",pid=3226769,fd=7)) + +``ps -fp $(pidof receptor)`` +``lsof -p `` + +``Unit ID`` is a unique identifier for a work unit (job). When running the ``work cancel`` command, you should specify the ``Unit ID`` for the Receptor instance to which you are connected.