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

Wantes to access dashboard via ip from remote host within same network #66

Closed
senthilkumarmoorthy opened this issue Nov 4, 2022 · 9 comments
Labels
good first issue Good for newcomers

Comments

@senthilkumarmoorthy
Copy link

Hello, I deployed EMBA first and realized that I need a dashboard also so I deployed embark and this is in the esx server running a VM with Ubuntu Server 22.04.

I added
10.x.x.x embark.local
embark.local 10.x.x.x
in /etc/hosts

edited /var/www/httpd80/httpd.conf and added ip under redirect permanent but still I couldn’t access the dashboard using http://10.x.x.x:80 within being in the same network.

Please advise.

@BenediktMKuehne
Copy link
Member

Hi,
did you try using http://embark.local ?

@BenediktMKuehne
Copy link
Member

The requests send to the server have to match the servername.
(run-server.sh line 205)

@BenediktMKuehne BenediktMKuehne added the good first issue Good for newcomers label Nov 4, 2022
@senthilkumarmoorthy
Copy link
Author

Hi,
did you try using http://embark.local ?

http://embark.local works fine locally. I mean I can access the dashboard from with in the VM. But I’m trying to access the dashboard from another machine. The machine from which I’m trying to access Embark VM both are on the same network. If I try to access embark host from other machine using http://10.x.x.x:80 I get you don’t have permission to access the resource message, even though I have registered a account to access embark dashboard.

@BenediktMKuehne
Copy link
Member

The url has to stay the same regardless of the IP, since the Apache server only accepts requests with the same name. (name-virtual host)
That's why the /etc/hosts entry is needed.

  1. Run server on VM/Server
  2. Do routing if necessary
  3. Add DNS resolve for embark.local to the correct host/ip:
    • if dns server: add entry
    • no dns -> edit hosts file (c:\windows\system32\drivers\etc\hosts.file on windows) on every client

Alternatively you could try adding an alias:
--server-alias <HOSTNAME/IP> at run-server.sh line 205
but I never tried that

@jblu42
Copy link

jblu42 commented Nov 7, 2022

Was also looking for this. Just tried to modify the run-server.sh and added the line --server-alias and it works. Would be great to have this as an option (e.g. command line or config file) and/or quickly describe this in the README. Makes it possible to run EMBARK on a headless server.

@senthilkumarmoorthy
Copy link
Author

Again, this works if the dashboard is accessed from the same host where the instance is deployed. Did you trying accessing the dashboard using the ip:port from a different host within the same network.?

@jblu42
Copy link

jblu42 commented Nov 7, 2022

@senthilkumarmoorthy Yes, just tried it. I added the line to run-server.sh at line 205 (--server-alias 192.168.0.55). The server runs in a VM with the IP 192.168.0.55. I can access EMBARK from a Browser on another system with http://192.168.0.55

Did not change anything else in EMBARK or host.

@senthilkumarmoorthy
Copy link
Author

I will do a fresh installation then. Thank you so much everyone so far.

@senthilkumarmoorthy
Copy link
Author

Great. It worked. I deployed it in a new VM and works flawlessly. Thank you @BenediktMKuehne & @jblu42

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

No branches or pull requests

3 participants