Skip to content

Commit 85e45c7

Browse files
committed
rename secure to tls
Signed-off-by: Asher Pemberton <asher.pemberton@arm.com> Reviewed-by: Asher Pemberton <asher.pemberton@arm.com> # gatekeeper
1 parent 474dfb9 commit 85e45c7

12 files changed

Lines changed: 48 additions & 39 deletions

doc/getting_started.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -438,15 +438,15 @@ Follow these instructions to install the systemd files on your machine(s):
438438
Enabling gRPC connection security
439439
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
440440

441-
It is encouraged to secure gRPC channels in a production environment.
441+
It is encouraged to use TLS for gRPC channels in a production environment.
442442

443-
This can be enabled on the ``labgrid-coordinator`` by adding the ``--secure``,
443+
This can be enabled on the ``labgrid-coordinator`` by adding the ``--tls``,
444444
``--cert`` and ``--key`` options.
445445
Refer to the ``labgrid-coordinator`` man page for details.
446446

447447
When you are connecting with ``labgrid-client`` or ``labgrid-exporter`` to a
448-
``labgrid-coordinator``that has secure gRPC channels enabled you need to pass
449-
the ``--secure`` (and ``--cert`` if the certificate is not trusted by the host
448+
``labgrid-coordinator`` that has TLS gRPC channels enabled you need to pass
449+
the ``--tls`` (and ``--cert`` if the certificate is not trusted by the host
450450
machine) option.
451451
Refer to the ``labgrid-client`` and ``labgrid-exporter`` man pages for details.
452452

doc/man/client.rst

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,11 @@ LG_COORDINATOR
5454
This variable can be used to set the default coordinator in the format
5555
``HOST[:PORT]`` (instead of using the ``-x`` option).
5656

57+
LG_COORDINATOR_TLS
58+
~~~~~~~~~~~~~~~~~~
59+
This variable can be set to enable TLS gRPC channels without using the
60+
``--tls`` option.
61+
5762
LG_PROXY
5863
~~~~~~~~
5964
This variable can be used to specify a SSH proxy hostname which should be used
@@ -128,11 +133,11 @@ Add all resources with the group "example-group" to the place example-place:
128133
129134
$ labgrid-client -p example-place add-match */example-group/*/*
130135
131-
Retrieve a list of places on a ``labgrid-coordinator`` that uses secure gRPC channels:
136+
Retrieve a list of places on a ``labgrid-coordinator`` that uses TLS gRPC channels:
132137

133138
.. code-block:: bash
134139
135-
$ labgrid-client --secure [--cert PATH] places
140+
$ labgrid-client --tls [--cert PATH] places
136141
137142
See Also
138143
--------

doc/man/coordinator.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ OPTIONS
2525
display command line help
2626
-l ADDRESS, --listen ADDRESS
2727
make coordinator listen on host and port
28-
--secure
28+
--tls
2929
enable TLS gRPC channel
3030
--cert
3131
path to TLS certificate (in PEM format)

doc/man/exporter.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ OPTIONS
2727
display command line help
2828
-x, --coordinator
2929
coordinator ``HOST[:PORT]`` to connect to, defaults to ``127.0.0.1:20408``
30-
--secure
30+
--tls
3131
enable TLS gRPC channel
3232
--cert
3333
path to TLS certificate (in PEM format)
@@ -103,11 +103,11 @@ Same as above, but with name ``myname``:
103103
104104
$ labgrid-exporter -n myname my-config.yaml
105105
106-
Same as above, but connecting to a ``labgrid-coordinator`` that uses secure gRPC channels:
106+
Same as above, but connecting to a ``labgrid-coordinator`` that uses TLS gRPC channels:
107107

108108
.. code-block:: bash
109109
110-
$ labgrid-exporter --secure [--cert PATH] -n myname my-config.yaml
110+
$ labgrid-exporter --tls [--cert PATH] -n myname my-config.yaml
111111
112112
SEE ALSO
113113
--------

labgrid/remote/client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1864,9 +1864,9 @@ def get_parser(auto_doc_mode=False) -> "argparse.ArgumentParser | AutoProgramArg
18641864
help="coordinator HOST[:PORT] (default: value from env variable LG_COORDINATOR, otherwise 127.0.0.1:20408)",
18651865
)
18661866
parser.add_argument(
1867-
"--secure",
1867+
"--tls",
18681868
action="store_true",
1869-
default=os.environ.get("LG_COORDINATOR_SECURE") is not None,
1869+
default=os.environ.get("LG_COORDINATOR_TLS") is not None,
18701870
help="enable TLS gRPC channel",
18711871
)
18721872
parser.add_argument("--cert", type=pathlib.PurePath, help="path to the server's TLS certificate (in PEM format)")

labgrid/remote/common.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ def _fetch_root_certificates():
105105

106106

107107
def get_client_credentials(args: Namespace) -> Optional[grpc.ChannelCredentials]:
108-
if not args.secure:
108+
if not args.tls:
109109
return None
110110

111111
if not args.cert:

labgrid/remote/coordinator.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1181,11 +1181,11 @@ def callback():
11811181

11821182

11831183
def get_server_credentials(args: argparse.Namespace) -> Optional[grpc.ServerCredentials]:
1184-
if not args.secure:
1184+
if not args.tls:
11851185
return None
11861186

11871187
if not args.cert or not args.key:
1188-
raise RuntimeError("--cert and --key must be provided when --secure is provided")
1188+
raise RuntimeError("--cert and --key must be provided when --tls is provided")
11891189

11901190
with open(args.key, "rb") as fk:
11911191
with open(args.cert, "rb") as fc:
@@ -1202,7 +1202,7 @@ def main():
12021202
default="[::]:20408",
12031203
help="coordinator listening host and port",
12041204
)
1205-
parser.add_argument("--secure", action="store_true", default=False, help="enable TLS to secure the gRPC channel")
1205+
parser.add_argument("--tls", action="store_true", default=False, help="enable TLS gRPC channel")
12061206
parser.add_argument("--cert", type=pathlib.PurePath, help="path to TLS certificate (in PEM format)")
12071207
parser.add_argument("--key", type=pathlib.PurePath, help="path to TLS key (in PEM format)")
12081208
parser.add_argument("-d", "--debug", action="store_true", default=False, help="enable debug mode")

labgrid/remote/exporter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1089,7 +1089,7 @@ def main():
10891089
default=os.environ.get("LG_COORDINATOR", "127.0.0.1:20408"),
10901090
help="coordinator host and port",
10911091
)
1092-
parser.add_argument("--secure", action="store_true", default=False, help="enable TLS to secure the gRPC channel")
1092+
parser.add_argument("--tls", action="store_true", default=False, help="enable TLS gRPC channel")
10931093
parser.add_argument("--cert", type=pathlib.PurePath, help="path to TLS certificate (in PEM format)")
10941094
parser.add_argument(
10951095
"-n",

man/labgrid-client.1

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ This is the client to control a boards status and interface with it on remote ma
3939
.INDENT 3.5
4040
.sp
4141
.EX
42-
usage: labgrid\-client [\-x ADDRESS] [\-\-secure] [\-\-cert CERT] [\-c CONFIG]
42+
usage: labgrid\-client [\-x ADDRESS] [\-\-tls] [\-\-cert CERT] [\-c CONFIG]
4343
[\-p PLACE] [\-s STATE] [\-i INITIAL_STATE] [\-d] [\-v]
4444
[\-P PROXY]
4545
COMMAND ...
@@ -53,7 +53,7 @@ coordinator HOST[:PORT] (default: value from env variable LG_COORDINATOR, otherw
5353
.UNINDENT
5454
.INDENT 0.0
5555
.TP
56-
.B \-\-secure
56+
.B \-\-tls
5757
enable TLS gRPC channel
5858
.UNINDENT
5959
.INDENT 0.0
@@ -1160,6 +1160,10 @@ using the \fB\-\-config\fP option, the \fB\-\-config\fP option overrides it.
11601160
.sp
11611161
This variable can be used to set the default coordinator in the format
11621162
\fBHOST[:PORT]\fP (instead of using the \fB\-x\fP option).
1163+
.SS LG_COORDINATOR_TLS
1164+
.sp
1165+
This variable can be set to enable TLS gRPC channels without using the
1166+
\fB\-\-tls\fP option.
11631167
.SS LG_PROXY
11641168
.sp
11651169
This variable can be used to specify a SSH proxy hostname which should be used
@@ -1242,12 +1246,12 @@ $ labgrid\-client \-p example\-place add\-match */example\-group/*/*
12421246
.UNINDENT
12431247
.UNINDENT
12441248
.sp
1245-
Retrieve a list of places on a \fBlabgrid\-coordinator\fP that uses secure gRPC channels:
1249+
Retrieve a list of places on a \fBlabgrid\-coordinator\fP that uses TLS gRPC channels:
12461250
.INDENT 0.0
12471251
.INDENT 3.5
12481252
.sp
12491253
.EX
1250-
$ labgrid\-client \-\-secure [\-\-cert PATH] places
1254+
$ labgrid\-client \-\-tls [\-\-cert PATH] places
12511255
.EE
12521256
.UNINDENT
12531257
.UNINDENT

man/labgrid-coordinator.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ display command line help
5151
.BI \-l \ ADDRESS\fR,\fB \ \-\-listen \ ADDRESS
5252
make coordinator listen on host and port
5353
.TP
54-
.B \-\-secure
54+
.B \-\-tls
5555
enable TLS gRPC channel
5656
.TP
5757
.B \-\-cert

0 commit comments

Comments
 (0)