Thursday, May 2, 2024
 Popular · Latest · Hot · Upcoming
2
rated 0 times [  2] [ 0]  / answers: 1 / hits: 2011  / 2 Years ago, sat, april 30, 2022, 5:08:17

I'm a complete noob at running my own server, and I want to install 3 different sites to be served from my Mythbuntu 14.04 system at home. What I want to do is not for actual public access though, but just me and maybe a small circle of other people.
However, I want the sites to be publicly reachable in the sense that I can access them from any place outside my home network. However, I don't want to rent a domain for them, but access them just by the IP addresses.



My question is: how about public IP addresses? Do I need to have as many as the number of sites I want to host?
I have a normal home DSL internet connection, and I think my ISP may only be handing me a dynamic IP address - but I still have to verify that, it may also be static.
In short, is it possible to host like three sites, accessible from outside, on the same box, over this infrastructure, or would I need to make arrangements with my ISP for a different setup?



EDIT: Thanks for your answers, I'm not sure though I got it all figured out:



It seems that If I have a static IP, I don't need the DynDNS service, correct? It seems that I actually might, but I sent e-mail to my ISP to confirm (EDIT: no, it's dynamic).



Checking my router's control panel, I can't find a proper interface for port management. This router actually belongs to the ISP, it's a Technicolor Gateway TG788A1vn.



It has a panel for managing firewall settings with just three preset security levels, and basically that's it for managing the firewall!



firewall settings



In addition, I can "assign" applications,



applications assignment. "hermann" in this image is my server box



I suppose the router manages the respective ports, but I'm not sure if "assigning" the https server means it gets to communicate through port 80. Would you think that's what this panel does?



About the domain name vs. IP-only, I'm not actually opposed to using a domain (although IP-only might have a small security benefit?), I just don't want the extra cost. I wasn't aware there are free domains available, so that's good to know! :-)


More From » apache2

 Answers
5

I would advise the following:




  1. Get a static IP address (honestly, so much easier). I assume (from now on) that you have opened up port 80.


  2. Register a TLD (top level domain) - free ones are available, such as freenom.com




    1. Click Register a New Domain enter image description here


    2. Chose the domain you want, click search multiple TLDs and then select the top row. Click check availability. enter image description here


    3. Select the one you want, click the amount of time, then order now. enter image description here


    4. Complete the fields (100% free) enter image description here


    5. You will be sent back to the home page. Go to your domains... enter image description here


    6. Click manage domain. enter image description here


    7. Click Management Tools and then URL Forwarding. Forward it to a random website (like http://google.com) enter image description hereenter image description here




    That's registered!


  3. Now for the DNS



    Sign up to freedns.afraid.org, and add your domain. Steps how to follow:




    1. Sign up (free), then Click "domains", at the side


    2. Click add domain enter image description here


    3. Enter the domain, and see the highlighted section. We have to go back to freenom for that. enter image description here


    4. Go to manage domains again, and select manage this domain. enter image description here enter image description here


    5. Select Manage Freenom DNS enter image description here


    6. Select Before using this service, please click here to activate Freenom Default Name Servers.. enter image description here


    7. Finally, enter into the fields the following:



      enter image description here




      NS1.AFRAID.ORG

      NS2.AFRAID.ORG

      NS3.AFRAID.ORG

      NS4.AFRAID.ORG



    8. Go back to Free-DNS and click submit enter image description here


    9. Ignore the warning, and just click subdomains. enter image description here


    10. Click add enter image description here


    11. Enter the relevant details, and click save. Repeat for the other subdomains. enter image description here


    12. Enter your domain and click trace. This can speed up the time it takes to start working. enter image description here


    13. Wait for the changes to propagate across the internet - for me it was about 24 hours. I watched funny cat videos: enter image description here



  4. Now we have to set up apache.




    1. Make 3 folders in the root (/var/www/html) and give them sensible names. In each of those you need an index.html file (or whatever you do with your gaming set up, just separate it into 3).


    2. Use this command to open the file in gedit:



      sudo gedit /etc/apache2/sites-enabled/000-default.conf

    3. Add in the following lines, at the end. I put it above the # vim: syntax=apache ts=4 sw=4 sts=4 sr noet line, but that makes no difference from what I know.



      <VirtualHost *:80>
      DocumentRoot "/var/www/html/game1" #Edit this line to have the correct folder name
      ServerName game1.mynametestdomain.tk #Edit this line to have the correct subdomain name
      </VirtualHost>

      <VirtualHost *:80>
      DocumentRoot "/var/www/html/game2" #Edit this line to have the correct folder name
      ServerName game2.mynametestdomain.tk #Edit this line to have the correct subdomain name
      </VirtualHost>

      <VirtualHost *:80>
      DocumentRoot "/var/www/html/game3" #Edit this line to have the correct folder name
      ServerName game3.mynametestdomain.tk #Edit this line to have the correct subdomain name
      </VirtualHost>

    4. Restart apache with



      sudo service apache2 restart




Make sure everything is working (as I said, it may take 24 hours+ to set everything up.




  1. Finally, set up an index.html in the root that has the links to the other pages - just in case they visit your ip address.


[#23392] Saturday, April 30, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
bathtusain

Total Points: 380
Total Questions: 124
Total Answers: 111

Location: Trinidad and Tobago
Member since Sat, Apr 9, 2022
2 Years ago
;