Azeroth-Core/Docker - LAN Setup - docker

I am looking to setup AzerothCore for LAN only use.
I am using an ESXi install with an Ubuntu 20.4.3 instance with latest Docker and Portainer for management. I am able to walk through the install process and it works great.
I switched the realmlist in the database to the LAN IP via HeidiSQL, setting both address and localaddress to LAN IP. I have tried just address and localaddress, leaving the other at 127.0.0.1.
I am using a fresh client install and set realmlist there too. I have tried both the dns and the IP, currently set to LAN IP.
I have not touched the compose file or modified authserver or worldserver config files. I am not certain where to look or what to change.
I am able to login with the ID I created all the way to see the Realm, which I select and hit enter. After a short pause the client screen returns to the realm selection screen. Not knowing the backend, I am not sure what is missing now.

Related

How do I change the IP address that Node-RED is hosted on?

I've been trying to configure Node-RED running locally at http://localhost:1880 to run on a static IP address that I would configured via my router's "DHCP Static IP Configuration" so that Node-RED could be accessible within the entire LAN.
How would I go about changing the IP address that Node-RED is hosted on, cause I haven't seemed to find any resources for it.
Would love to know the exact approach of running Node-RED on a LAN via a router; like should the static IP address be assigned to a particular device with a specific MAC address or can Node-RED reside on the router itself.
By default Node-RED binds to 0.0.0.0 which is the shortcut to say bind to all available interfaces (the log says to access via http://localhost:1880 because this will always be available). You should find that if you know the IP address of the machine running Node-RED and you enter http://ip-address:1880 from another machine on your LAN it should connect to the Node-RED editor.
You can change this bind address in the settings.js file (found in the userDir which is logged early on when Node-RED starts and is by default in ~/.node-red on a Linux/Unix machine). You can uncomment the uiHost line and change the IP address to what ever the static IP address of your host machine is. Under 99.9% of circumstances you should not do this and just leave it as the default 0.0.0.0
As for how you set your device that is hosting Node-RED to have a fixed IP address, that will be entirely dependent on the type of router you have, but usual approach would be to set the routers built in DHCP server to just asign a static IP address to that device as identified by it's MAC address. This means that you do not need to change anything on the device.
It is unlikely you will be able (or want) to to run Node-RED actually on your router, most home (or enterprise) routers are specialist devices and running a programming environment like Node-RED on them is really not a good idea from a security point of view unless you 110% know what you are doing.
Speaking of security, make sure you enable adminAuth in your settings.js before setting up any port forwarding on the router to expose Node-RED to the outside world. An unsecured Node-RED editor is likely to be quickly scanned by something like Shodan and promptly ushttps://nodered.org/docs/user-guide/runtime/securing-node-reded to host Crypto mining or much worse. Read the following carefully https://nodered.org/docs/user-guide/runtime/securing-node-red

Azerothcore connecting to internet via Docker

I have Azerothcore fresh installed using install with Docker method.
I am able to connect over local network using SET realmlist 192.168.1.242
What is the best method to get docker or server to allow a friend to access over the internet? Do I have to follow a different install method? Wiki isn't very clear on this.
Modify the address column of the realmlist table inside your acore_auth database and put there your public IP address.
Be aware that if you don't have a static IP address, then that value will frequently change. Also, you need to open the ports 3724 and 8085 of your router.
If you can't open your router ports, you can try using some VPN like hamachi (in that case, your public address should be your hamachi one and your friends need to be in the same hamachi room of yours). This solves also the dynamic IP issue.

How to access rails server in a remote VM

I set up a Virtual Machine (VM) on OpenStack remotely. The VM is running Red Hat Enterprise Linux (RHEL) 7.
I ssh into the above VM using ssh vm-url, and then I setup a rails server during that ssh session and get it running using rails server -b vm-url
Now, I try to access the rails website above from my local Chrome browser by typing the URL vm-url:3000 into Chrome's address bar (the Omnibox), but I get:
This site can’t be reached
10.150.8.101 took too long to respond.
Why Can't I access the rails website, what have I done wrong?
Please correct me if any terminologies I used are incorrect.
Thank you.
Two things to check,
The ip attached to the VM is public and accessible
Http port is enabled to be accessed from outside
The port accessed is handled in security groups which is generally configured while creating the instance. Either add new security group with enough privileges or update the same with new added ports.

Connect to rails server remotely from raspberry pi

I have ssh'd into my rasberry pi and built a rails application.
Now how do I load the rails app from another machine?
I have tried IP:port in a web browser, but this fails.
Can I use ssh from a web browser to load the rails server process?
Are there gems I need to install to do this?
Is there any good documentation that I have missed?
SOLUTION
use ngrok to tunnel https://medium.com/#karimbutt/using-ngrok-to-create-a-publicly-accessible-web-facing-raspberry-pi-server-35deef8c816a#.sraso7zar
Maybe the problem is with the IP address you're trying to use. Servers don't necessarily forward their public IP traffic to localhost automatically.
Perhaps you could configure the IP address somehow, I don't know (others might?). Alternatively, you have a use a "local tunnel" service like ngrok or localtunnel. What these do is create a public URL for your localhost (i.e. your "loopback" address), so anyone can access it.
I spoke with a Ngrok author via email. He ensured me that I shouldn't need to expect any downtime from the service or to have to manually restart it. Although keep in mind that if you're on the free plan, whenever you restart Ngrok you're going to get a different URL. He also described it as kind of like a "souped up SSH -R"

How do you host a Ruby on Rails application on a local network, so multiple people can access it?

I'm brand new to RoR and have pretty much 0 experience with it. I have been handed down somebody else's project and I need to find a way to host the application, so people can just access it locally. The application is a spider script/walker script/web scraper whatever you call it. Basically it connects to a website, logs in, retrieves certain data each day and maps it with the previous data. While on the local machine, you use it, go to localhost:3000, and you get the webpage the previous person designed. I was just wondering how I could get that page to be public for the people on our local network, so they could connect to some arbitrary IP and see the same page (it updates daily)?
What I tried doing is making the folder containing the application public to the network, but in order to use it, I would have to make everybody on the network allowed to write to it and each person would have to install RoR to use it. I want to avoid that since it doesn't seem logical, nor is it what I'm trying to do.
Looking at the code, I can reverse engineer and understand what it does, but when it comes to hosting web apps locally or something of that sort, I have never done this before. Please help!
Thanks in advance!
**EDIT
-This is all being done on a Windows 7 machine.
Since you're on Windows, open up a command line and run ipconfig to find out your local IP. It will be listed under 'IP Address'.
Tell people in your LAN to access http://192.168.x.x:3000 replacing 192.168.x.x by your IP address from step 1.
EDIT: One major thing that I missed, you are windows. On windows u could use thin and put it behind a load balancer. Although i would suggest hosting it on a UNIX machine :)
Although Running it in webrick(webrick is the application server for development i.e when u run rails s) will let other users access the website NEVER do the same for a production application. If you want to run this application in production, u need more powerful application servers like passenger. I would suggest you use it with Apache or Nginx instead of stand alone passenger. Once all this is setup others can use your application by entering the IP(xx.xx.xx.xx) also u can ask your system admin to setup a local DNS so your users need not remember the IP address always.
Description:
While starting Rails Server, we can also setup some options to configure the IP address and also the port number of the site under development environment to host the website in local network. So if we want to change the IP from http://127.0.0.1:3000 to http://192.168.x.x:port (x= 0 to 255 any one number), we can set that in Rails server command! But for this, we will need to find out our current IP address at our current network which will help us to serve the website in local network.
So at first step:
We will open our terminal on our PC. For Android user, we need to open Termux app. Then simply type ifconfig to get the IP address of our device in the current network. We will get an output like this one (Here I'm using Android device for development. So output might be something different than this one on your PC terminal but the process is same):
$ ifconfig
Warning: cannot open /proc/net/dev (Permission denied). Limited output.
lo: flags=XX<UP,LOOPBACK,RUNNING> mtu XXXXX
inet 127.0.0.1 netmask 255.XXX.XXX.XXX
unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen XXXX (UNSPEC)
wlan0: flags=XXXX<UP,BROADCAST,RUNNING,MULTICAST> mtu XXXX
inet 192.168.1.103 netmask 255.XXX.XXX.XXX broadcast 192.168.1.255
unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen XXXX (UNSPEC)
X= some numbers with our device credentials which is dummied with this variable
If you are using a WiFi router then we will need the wlan0 part to get our device IP. Under wlan0 section there is a subsection of inet showing our current IP! YUP, we need that IP address 192.168.1.103! This might be different for your device and network. This is the key of this mission! Now we're going to the second important step.
So the Second Step is:
That required input command to configure the IP address.
rails s -b 192.168.1.103 -p 8080
Here:
rails s for rails server
-b 192.168.1.103 for bidding the IP address for customisation from the default IP http://127.0.0.1 which is our localhost address.
-p 8080 for port setup. This part is optional. Default port is 3000.
This is the process of changing the localhost IP (http://127.0.0.1) to local network IP which will be available for other device of the same network user.
Now our rails app is available in our local network! Other users in the same network will also be able to visit the website while the server command is running. And the link will be http://192.168.1.103:8080 if you also configure the port number. Otherwise if you have used the command rails s -b 192.168.1.103 without port configuration the link will be: http://192.168.1.103:3000
Again: 192.168.1.103 was for my case, your IP address will be different for your device. That will be needed to use for your server and link address.

Resources