8000 Access Portworx endpoint over Kubernetes · Issue #40 · portworx/pxc · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Mar 26, 2025. It is now read-only.

Access Portworx endpoint over Kubernetes #40

Closed
lpabon opened this issue Aug 6, 2019 · 1 comment
Closed

Access Portworx endpoint over Kubernetes #40

lpabon opened this issue Aug 6, 2019 · 1 comment

Comments

@lpabon
Copy link
Contributor
lpabon commented Aug 6, 2019

When setting up Portworx with a cloud provider, the user may not have easy access to the Portworx gRPC endpoints.

Using port forward

One workaround is to use port-forward on the local system:

  • First portforward local port 9908 to the portworx-api service port 9020 on Kubernetes:
$ kubectl -n kube-system port-forward svc/portworx-api 9908:9020
Forwarding from 127.0.0.1:9908 -> 9020
Forwarding from [::1]:9908 -> 9020
  • Then add a new context which points to the local port created above:
$ px context create testlocal --endpoint 127.0.0.1:9908  --kubeconfig=/path/to/kubeconfig
New context testlocal saved to /home/lpabon/.px/config.yml
  • Then set the context to the one created and send a command
$ px context set testlocal
testlocal is now the current context
  • Now send the command
$ px describe cluster
Cluster ID: torpedo-tp-2-2-basic-vol-driver_spDdryEuGzeNu_19_07_31_13_46_28
Cluster UUID: 71e17535-fdf8-4cc7-b08f-5974e36a5042
Cluster Status: STATUS_OK
Version: 2.2.0.0-b25c00d
  build: b25c00d94bdd754b5da6ae2f3b8938f52a9db33f
SDK Version 0.42.15

Hostname                              IP           SchedulerNodeName                     Used   Capacity  Status
--------                              --           -----------------                     ----   --------  ------
torpedo-tp-2-2-basic-vol-driver-30-1  70.0.80.150  torpedo-tp-2-2-basic-vol-driver-30-1  28 Gi  762 Gi    STATUS_OK
...

Px enhancement

We may need a method (future milestone) to create and destroy a portforward on demand when each command is created.

@lpabon
Copy link
Contributor Author
lpabon commented Jan 31, 2020

fixed by #81

@lpabon lpabon closed this as completed Jan 31, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant
0