File tree Expand file tree Collapse file tree 2 files changed +30
-13
lines changed Expand file tree Collapse file tree 2 files changed +30
-13
lines changed Original file line number Diff line number Diff line change @@ -173,6 +173,36 @@ jobs:
173173 with :
174174 user-name : sdk-user
175175
176+ - name : Grant sdk-user port-forwarding permissions
177+ run : |
178+ cat <<EOF | kubectl apply -f -
179+ apiVersion: rbac.authorization.k8s.io/v1
180+ kind: ClusterRole
181+ metadata:
182+ name: port-forward-permissions
183+ rules:
184+ - apiGroups: [""]
185+ resources: ["services", "pods"]
186+ verbs: ["get", "list", "watch"]
187+ - apiGroups: [""]
188+ resources: ["pods/portforward"]
189+ verbs: ["create"]
190+ ---
191+ apiVersion: rbac.authorization.k8s.io/v1
192+ kind: ClusterRoleBinding
193+ metadata:
194+ name: sdk-user-port-forward-binding
195+ subjects:
196+ - kind: User
197+ name: sdk-user
198+ apiGroup: rbac.authorization.k8s.io
199+ roleRef:
200+ kind: ClusterRole
201+ name: port-forward-permissions
202+ apiGroup: rbac.authorization.k8s.io
203+ EOF
204+ shell : bash
205+
176206 - name : Configure RBAC for sdk user with limited permissions
177207 run : |
178208 kubectl create clusterrole list-ingresses --verb=get,list --resource=ingresses
Original file line number Diff line number Diff line change @@ -246,19 +246,6 @@ def run_local_interactives(
246246 generate_cert .generate_tls_cert (cluster_name , self .namespace )
247247 generate_cert .export_env (cluster_name , self .namespace )
248248
249- # Unset server cert/key for client mode if skip_verify is true, to avoid client trying to use them as its own identity.
250- if os .environ .get ("RAY_CLIENT_SKIP_TLS_VERIFY" ) == "1" :
251- if "RAY_TLS_SERVER_CERT" in os .environ :
252- del os .environ ["RAY_TLS_SERVER_CERT" ]
253- logger .info (
254- "Removed RAY_TLS_SERVER_CERT from env for client connection"
255- )
256- if "RAY_TLS_SERVER_KEY" in os .environ :
257- del os .environ ["RAY_TLS_SERVER_KEY" ]
258- logger .info (
259- "Removed RAY_TLS_SERVER_KEY from env for client connection"
260- )
261-
262249 # Start port forwarding
263250 local_port = "20001"
264251 ray_client_port = "10001"
You can’t perform that action at this time.
0 commit comments