lucascebertin / otserv-automation

A simple automation to get a otserv up and running
MIT License
3 stars 0 forks source link

External Access and fail establish connection #1

Open HelloMyDevWorld opened 5 years ago

HelloMyDevWorld commented 5 years ago

Hey,

Is there any solution to get external access to server, because i have fail to establish connection ?

BR

lucascebertin commented 5 years ago

Hello, could you give me more details?

Are you running rhe server on your own computer and trying do connect from the internet?

I have done a cloud setup where the config points to a domain name, so you just need something like ngrok to create a http tunnel or a real dns pointing to your server.

HelloMyDevWorld commented 5 years ago

Hey,

I tried to start it from VM machine (Ubuntu 16.04-LTS for Azure Batch container pools) on Azure Portal also locally on windows 10. When i connect from the same PC as server everythings works perfect, but when i try to get access form external i cannot get server, only website.

Unlocked ports: 7171, 7172, 3306, 33060, 8080, 80

There is a bunch of people talking about changing server/config.lua

The is also small changes to fix in repo i think: Comment out #RUN chmod -R 777 /var/www/html/engine/cache/ Changed from windows to (Linux LF) on file otserv-automation/server/wait-for.sh

Also used DNS A from Azure working on x.x.com

HelloMyDevWorld commented 5 years ago

So you use ngrok for which ports ?

image

Still doesnt work

lucascebertin commented 5 years ago

There is another port to open, 7173 but with your actual firewall rules would be possible to log in. About the config.lua, you can change it inside the volume folder. Just open it, change it ip server with your actual IP ou the domain name, save it and restart the server. For ngrok, there is a way to open all ports defined on your rules but you need to create an yml file following some guidance on the ngrok docs.

Did you already changed the config inside volume folder?

HelloMyDevWorld commented 5 years ago

The problem was missing 127.0.0.1 => my IP under volumen config.lua :) Now everything is working 💃

HelloMyDevWorld commented 5 years ago

You can also add empty folder under html/engine/cache/ to make works from the box #RUN chmod -R 777 /var/www/html/engine/cache/

There is only one problem with: Cannot start session when headers already sent in /var/www/html/engine/init.php on line 23

It would be cool to add some new design for website

lucascebertin commented 5 years ago

Nice that's working now! Do you mind to send this fix in a Pull Request?

About the design, probably the correct place to open to znote aac repo... I'm not that good with design or PHP :(

HelloMyDevWorld commented 5 years ago

Have you tried to edit that global map by editor ? Remere 3.5 ? Because i cannot load map to it ;/

lucascebertin commented 5 years ago

Sorry mate, I didn't :( What happens when you try to open?

HelloMyDevWorld commented 5 years ago

It's working now :) I am trying to run it outside but anyone wants to play ;D