File tree Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Expand file tree Collapse file tree 2 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -2086,7 +2086,7 @@ NAMESPACE and CONTEXT are used to identify the resource type to query for."
2086
2086
(port (if (string-equal (oref resource kind) " services" )
2087
2087
(completing-read " Port: "
2088
2088
(-map (lambda (port-spec ) (number-to-string (alist-get 'port port-spec)))
2089
- (kele--service -ports resource))
2089
+ (kele--get -ports-for-resource resource))
2090
2090
nil t )
2091
2091
(number-to-string (read-number " Port: " )))))
2092
2092
(list context ns gvk name port)))
@@ -2137,7 +2137,10 @@ PORTS is used according to `completion-extra-properties'."
2137
2137
(cl-defun kele--get-ports-for-resource (obj )
2138
2138
" Get the exposed ports for the resource OBJ.
2139
2139
2140
- OBJ must be a `kele--resource-container' ."
2140
+ OBJ must be a `kele--resource-container' .
2141
+
2142
+ Return value is a list of plists consisting of keys `name' ,
2143
+ `protocol' , and `port' ."
2141
2144
(pcase (alist-get 'kind (oref obj resource))
2142
2145
(" Service" (kele--service-ports obj))))
2143
2146
Original file line number Diff line number Diff line change @@ -744,8 +744,7 @@ metadata:
744
744
(protocol . " TCP" ))
745
745
((name . " foo" )
746
746
(containerPort . 9999 )
747
- (protocol
748
- . " TCP" ))))))))))))))))
747
+ (protocol . " TCP" ))))))))))))))))
749
748
:to-have-same-items-as
750
749
(list '((name . " whatever" ) (port . 1234 ) (protocol . " TCP" ))
751
750
'((name . " foo" ) (port . 5678 ) (protocol . " TCP" )))))
You can’t perform that action at this time.
0 commit comments