Skip to content

Instantly share code, notes, and snippets.

@medined
Created June 28, 2020 14:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save medined/7e28803ced7db85dd86b103cff1e9cb0 to your computer and use it in GitHub Desktop.
Save medined/7e28803ced7db85dd86b103cff1e9cb0 to your computer and use it in GitHub Desktop.
kubectl as reverse proxy
You can use `kubectl` as a reverse proxy so that it handles locating the API server and
authentication. It can run in the background but I like to use the foreground to make it easy
to stop.
```bash
kubectl proxy --port=8080
```
Now you can open another terminal to explore the API.
```bash
curl http://localhost:8080/api/
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment