Skip to content

Commit 2c4f25f

Browse files
doc: configuration: fix docker strategy documentation
In an initial version of the patch series, the strategy was called DockerShellStrategy. But that was changed before the PR was merged. So adjust the documentation to the actual existing DockerStrategy. Signed-off-by: Bastian Krause <bst@pengutronix.de>
1 parent e4dd576 commit 2c4f25f

1 file changed

Lines changed: 9 additions & 14 deletions

File tree

doc/configuration.rst

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2685,35 +2685,30 @@ to transition to the shell state:
26852685
this command would transition from the bootloader into a Linux shell and
26862686
activate the ShellDriver.
26872687

2688-
DockerShellStrategy
2689-
~~~~~~~~~~~~~~~~~~~
2690-
A DockerShellStrategy has three states:
2688+
DockerStrategy
2689+
~~~~~~~~~~~~~~
2690+
A DockerStrategy has three states:
26912691

26922692
- unknown
2693-
- off
2694-
- shell
2693+
- gone
2694+
- accessible
26952695

26962696

2697-
To transition to the shell state:
2697+
In order to use the DockerStrategy via labgrid as a library and transition to
2698+
the ``accessible`` state:
26982699

26992700
::
27002701

27012702
>>> from labgrid import Environment
27022703
>>> e = Environment("local.yaml")
27032704
>>> t = e.get_target("main")
2704-
>>> s = t.get_driver("DockerShellStrategy")
2705-
>>> s.transition("shell")
2706-
2705+
>>> s = t.get_driver("DockerStrategy")
2706+
>>> s.transition("accessible")
27072707

27082708
These commands would activate the docker driver which creates and starts
27092709
a docker container. This will subsequently make `NetworkService`_ instance(s)
27102710
available which can be used for e.g. SSH access.
27112711

2712-
Note: Transitioning to the "off" state will make any `NetworkService`_
2713-
instance(s) unresponsive - which may in turn invalidate SSH connection
2714-
sharing. Therefore, during automated test suites, refrain from transitioning
2715-
to the "off" state.
2716-
27172712
Reporters
27182713
---------
27192714

0 commit comments

Comments
 (0)