Skip to content

Commit c080c02

Browse files
authored
Documentation: fixing --parallel flag position and typos (#2858)
Fixing the --parallel flag position in the CLI reference and fixing typos. Also adding a line about running Molecule in parallel with other tools. Signed-off-by: Arnaud SINAYS <[email protected]>
1 parent 3e9b3c7 commit c080c02

File tree

5 files changed

+14
-11
lines changed

5 files changed

+14
-11
lines changed

docs/ci.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ we export a ``TOX_ENVNAME`` environment variable, it's the name of our tox env.
328328
329329
330330
You also must include the ``TOX_ENVNAME`` variable in name of each platform in
331-
``molecule.yml`` configuration file. This way, ther names won't create any
331+
``molecule.yml`` configuration file. This way, their names won't create any
332332
conflict.
333333

334334
.. code-block:: yaml

docs/examples.rst

+7-4
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ When needed, such security profiles can be reused (for example `the one availabl
216216
- /sys/fs/cgroup:/sys/fs/cgroup:ro
217217
218218
The developer can also opt to `start the container with extended privileges`_,
219-
by either giving it ``SYS_ADMIN`` capabilites or running it in ``privileged`` mode.
219+
by either giving it ``SYS_ADMIN`` capabilities or running it in ``privileged`` mode.
220220

221221
.. important::
222222

@@ -385,9 +385,6 @@ Running Molecule processes in parallel mode
385385

386386
It is currently only available for use with the Docker driver.
387387

388-
It is possible to run Molecule processes in parallel using another tool to
389-
orchestrate the parallelization (such as `GNU Parallel`_ or `Pytest`_).
390-
391388
When Molecule receives the ``--parallel`` flag it will generate a `UUID`_ for
392389
the duration of the testing sequence and will use that unique identifier to
393390
cache the run-time state for that process. The parallel Molecule processes
@@ -398,6 +395,12 @@ Molecule uses a new and separate caching folder for this in the
398395
``$HOME/.cache/molecule_parallel`` location. Molecule exposes a new environment
399396
variable ``MOLECULE_PARALLEL`` which can enable this functionality.
400397

398+
It is possible to run Molecule processes in parallel using another tool to
399+
orchestrate the parallelization (such as `GNU Parallel`_ or `Pytest`_).
400+
If you do so, make sure Molecule knows it is running in parallel mode by
401+
specifying the ``--parallel`` flag to your command(s) to avoid concurrency
402+
issues.
403+
401404
.. _GNU Parallel: https://www.gnu.org/software/parallel/
402405
.. _Pytest: https://docs.pytest.org/en/latest/
403406
.. _UUID: https://en.wikipedia.org/wiki/Universally_unique_identifier

molecule/command/check.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,9 @@ class Check(base.Base):
6565
Load an env file to read variables from when rendering
6666
molecule.yml.
6767
68-
.. program:: molecule --parallel check
68+
.. program:: molecule check --parallel
6969
70-
.. option:: molecule --parallel check
70+
.. option:: molecule check --parallel
7171
7272
Run in parallelizable mode.
7373
"""

molecule/command/destroy.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,9 @@ class Destroy(base.Base):
7979
Load an env file to read variables from when rendering
8080
molecule.yml.
8181
82-
.. program:: molecule --parallel destroy
82+
.. program:: molecule destroy --parallel
8383
84-
.. option:: molecule --parallel destroy
84+
.. option:: molecule destroy --parallel
8585
8686
Run in parallelizable mode.
8787
"""

molecule/command/test.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,9 @@ class Test(base.Base):
7979
Load an env file to read variables from when rendering
8080
molecule.yml.
8181
82-
.. program:: molecule --parallel test
82+
.. program:: molecule test --parallel
8383
84-
.. option:: molecule --parallel test
84+
.. option:: molecule test --parallel
8585
8686
Run in parallelizable mode.
8787
"""

0 commit comments

Comments
 (0)