Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ekz ui cannot access on browser #89

Open
wingyplus opened this issue Jun 15, 2021 · 2 comments
Open

ekz ui cannot access on browser #89

wingyplus opened this issue Jun 15, 2021 · 2 comments

Comments

@wingyplus
Copy link
Contributor

After calling ekz ui and open firefox with localhost:8080, browser show the error page with Unable to connect. I run docker ps to see what going with quay.io/ekz-io/ekz-webui container and found that it's doesn't expose port like screenshot below:

Screen Shot 2564-06-15 at 14 00 18

I'm not sure what I am wrong. :(

@wingyplus
Copy link
Contributor Author

Quick fix by following patch:

diff --git a/cmd/ekz/ui.go b/cmd/ekz/ui.go
index 31e2eef..de4ae1f 100644
--- a/cmd/ekz/ui.go
+++ b/cmd/ekz/ui.go
@@ -80,16 +80,18 @@ func uiCmdRun(cmd *cobra.Command, args []string) error {
 	logger.Waitingf("press Ctrl + C to stop the UI.")
 
 	if verbose {
-		out, err := script.Exec("docker", "run", "--network=host",
+		out, err := script.Exec("docker", "run",
 			"-v", expandKubeConfigFile()+":/root/.kube/config",
+			"-p", "8080:8080",
 			uiImage,
 		).CombinedOutput()
 		fmt.Print(string(out))
 		return err
 	} else {
 		err := script.Exec("docker", "run",
-			"--rm", "--network=host",
+			"--rm",
 			"-v", expandKubeConfigFile()+":/root/.kube/config",
+			"-p", "8080:8080",
 			uiImage,
 		).Run()
 		return err

The web UI can open:

Screen Shot 2564-06-15 at 14 19 49

@wingyplus wingyplus changed the title ekz ui cannot access webui ekz ui cannot access on browser Jun 15, 2021
@wingyplus
Copy link
Contributor Author

wingyplus commented Jun 15, 2021

I found it cannot access resources. If double click on context in Contexts menu, it show the error:

Screen Shot 2564-06-15 at 14 36 10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant