Skip to content

Commit 42a310e

Browse files
hreineckekawasaki
authored andcommitted
common/nvme: add '--tls' argument to _nvme_connect_subsys()
To start TLS-encrypted connections. Signed-off-by: Hannes Reinecke <[email protected]> Signed-off-by: Shin'ichiro Kawasaki <[email protected]>
1 parent 1999835 commit 42a310e

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

common/nvme

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,7 @@ _nvme_connect_subsys() {
276276
local no_wait=false
277277
local hdr_digest=false
278278
local data_digest=false
279+
local tls=false
279280
local port
280281
local i
281282
local -a ARGS
@@ -342,6 +343,10 @@ _nvme_connect_subsys() {
342343
data_digest=true
343344
shift 1
344345
;;
346+
--tls)
347+
tls=true
348+
shift 1
349+
;;
345350
*)
346351
echo "WARNING: unknown argument: $1"
347352
shift
@@ -399,6 +404,9 @@ _nvme_connect_subsys() {
399404
if [[ ${data_digest} = true ]]; then
400405
ARGS+=(--data-digest)
401406
fi
407+
if [[ ${tls} = true ]]; then
408+
ARGS+=(--tls)
409+
fi
402410
ARGS+=(-o json)
403411
connect=$(nvme connect "${ARGS[@]}" 2> /dev/null)
404412

0 commit comments

Comments
 (0)