Last active
February 6, 2020 02:06
-
-
Save brianpursley/291fbf3ced3b4144703b7c8637e7efb2 to your computer and use it in GitHub Desktop.
Script to get address of kubernetes nodeport service when running locally using (using kind for example)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
nodeport=$(kubectl get services -o jsonpath="{..nodePort}") && kubectl get node -o jsonpath="{..addresses[0].address}" | xargs -n1 printf -- "http://%s:$nodeport\n" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment