Skip to content

Commit 4db1b4e

Browse files
committed
Merge remote-tracking branch 'origin/docs-master'
* origin/docs-master: Import debug helper macros. Add extra/ to .gitignore. Import include processing bench docs: Get rid of a ton of blocking resources from theme. docs: update stats docs: update download link. docs: Google site verification Update README link docs: move confusing install step to noteworthy difference
2 parents 416027b + 5cb1cb2 commit 4db1b4e

File tree

8 files changed

+76
-14
lines changed

8 files changed

+76
-14
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ docs/_build/
1313
htmlcov/
1414
*.egg-info
1515
__pycache__/
16+
extra

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Mitogen
33

44
<!-- [![Build Status](https://travis-ci.org/dw/mitogen.png?branch=master)](https://travis-ci.org/dw/mitogen}) -->
5-
<a href="https://mitogen.readthedocs.io/">Please see the documentation</a>.
5+
<a href="https://mitogen.networkgenomics.com/">Please see the documentation</a>.
66

77
![](https://i.imgur.com/eBM6LhJ.gif)
88

docs/_templates/layout.html

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,35 @@
11
{% extends "!layout.html" %}
22
{% set css_files = css_files + ['_static/style.css'] %}
33

4+
{# We don't support Sphinx search, so don't let its JS either. #}
5+
{% block scripts %}
6+
{% endblock %}
7+
8+
{# Alabaster ships a completely useless custom.css, suppress it. #}
9+
{%- block extrahead %}
10+
<meta name="google-site-verification" content="oq5hNxRYo25tcfjfs3l6pPxfNgY3JzDYSpskc9q4TYI" />
11+
<meta name="viewport" content="width=device-width, initial-scale=0.9, maximum-scale=0.9" />
12+
{% endblock %}
13+
414
{% block footer %}
515
{{ super() }}
616

717
<script>
818
(function() {
919
{% include "piwik-config.js" %}
10-
var u="https://k1.botanicus.net/tr/";
20+
var u="https://networkgenomics.com/p/tr/";
1121
_paq.push(['setTrackerUrl', u+'ep']);
1222
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0]; g.type='text/javascript';
1323
g.defer=true; g.async=true; g.src=u+'js'; s.parentNode.insertBefore(g,s);
1424
})();
1525
</script>
16-
<noscript><p><img src="https://k1.botanicus.net/tr/ep?idsite=6" style="border:0" alt=""></p></noscript>
26+
27+
<noscript>
28+
<p>
29+
{% set fulltitle = (title|striptags|e) + titlesuffix -%}
30+
<img src="https://networkgenomics.com/p/tr/ep?idsite=6&action_name={{fulltitle}}" style="border:0" alt="">
31+
</p>
32+
</noscript>
1733

1834
<script async defer src="https://buttons.github.io/buttons.js"></script>
1935
{% endblock %}

docs/ansible_detailed.rst

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -75,13 +75,7 @@ Installation
7575
``mitogen_host_pinned`` strategies exists to mimic the ``free`` and
7676
``host_pinned`` strategies.
7777

78-
4. If targets have a restrictive ``sudoers`` file, add a rule like:
79-
80-
::
81-
82-
deploy = (ALL) NOPASSWD:/usr/bin/python -c*
83-
84-
5.
78+
4.
8579

8680
.. raw:: html
8781

@@ -103,7 +97,6 @@ Installation
10397
</form>
10498

10599

106-
107100
Demo
108101
~~~~
109102

@@ -172,6 +165,14 @@ Noteworthy Differences
172165
* The ``doas``, ``su`` and ``sudo`` become methods are available. File bugs to
173166
register interest in more.
174167

168+
* The ``sudo`` comands executed differ slightly compared to Ansible. In some
169+
cases where the target has a ``sudo`` configuration that restricts the exact
170+
commands allowed to run, it may be necessary to add a ``sudoers`` rule like:
171+
172+
::
173+
174+
your_ssh_username = (ALL) NOPASSWD:/usr/bin/python -c*
175+
175176
* The `docker <https://docs.ansible.com/ansible/2.6/plugins/connection/docker.html>`_,
176177
`jail <https://docs.ansible.com/ansible/2.6/plugins/connection/jail.html>`_,
177178
`kubectl <https://docs.ansible.com/ansible/2.6/plugins/connection/kubectl.html>`_,

docs/conf.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
import mitogen
66
VERSION = '%s.%s.%s' % mitogen.__version__
77

8-
author = u'David Wilson'
9-
copyright = u'2019, David Wilson'
8+
author = u'Network Genomics'
9+
copyright = u'2019, Network Genomics'
1010
exclude_patterns = ['_build']
1111
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.intersphinx', 'sphinxcontrib.programoutput']
1212
html_show_sourcelink = False
@@ -39,6 +39,6 @@
3939
4040
.. |mitogen_version| replace:: %(VERSION)s
4141
42-
.. |mitogen_url| replace:: `mitogen-%(VERSION)s.tar.gz <https://files.pythonhosted.org/packages/source/m/mitogen/mitogen-%(VERSION)s.tar.gz>`__
42+
.. |mitogen_url| replace:: `mitogen-%(VERSION)s.tar.gz <https://networkgenomics.com/try/mitogen-%(VERSION)s.tar.gz>`__
4343
4444
""" % locals()

scripts/debug-helpers.sh

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
#
2+
# Bash helpers for debugging.
3+
#
4+
5+
# Tell Ansible to write PID files for the mux and top-level process to CWD.
6+
export MITOGEN_SAVE_PIDS=1
7+
8+
9+
# strace -ff -p $(muxpid)
10+
muxpid() {
11+
cat .ansible-mux.pid
12+
}
13+
14+
# gdb -p $(anspid)
15+
anspid() {
16+
cat .ansible-controller.pid
17+
}
18+
19+
# perf top -git $(muxtids)
20+
# perf top -git $(muxtids)
21+
muxtids() {
22+
ls /proc/$(muxpid)/task | tr \\n ,
23+
}
24+
25+
# perf top -git $(anstids)
26+
anstids() {
27+
ls /proc/$(anspid)/task | tr \\n ,
28+
}
29+
30+
# ttrace $(muxpid) [.. options ..]
31+
# strace only threads of PID, not children
32+
ttrace() {
33+
local pid=$1; shift;
34+
local s=""
35+
for i in $(ls /proc/$pid/task) ; do
36+
s="-p $i $s"
37+
done
38+
strace $s "$@"
39+
}

tests/ansible/bench/_includes.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- meta: end_play

tests/ansible/bench/includes.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
- hosts: test-targets
2+
tasks:
3+
- include_tasks: _includes.yml
4+
with_sequence: start=1 end=1000

0 commit comments

Comments
 (0)