How to change public IP to a domain so my friends won't know my IP (WAN)

help

#1

Hello All,
New here, I’m using my old (20years) laptop and installed Dietpi and using it for Owncloud server.

  • OS = Dietpi (Debian Jessie OS)
  • LLAP = Lighttpd | Mariadb | PHP
  • Webserver = Lighttpd | PHP
  • Database type = MariaBD
  • DataFolder = /var/lib/owncloud/data
  • Database Name = owncloud

I’ve got it to work great, port forwarding is enable so I can use my server on WAN but my question is, is there a way to change my IP address into a domain name.

Example: https://Public IP/owncloud/ >> https://Thai/owncloud/

I want my friends to use my server as well but I don’t want them to know my IP address.

Do I have to pay for a domain? Or do I just change some configuration in my files on my server?

Thank you in advance.


#2

You could use a dynamic name service like NOIP.COM. That will allow you to create a domain name example.ddns.net that you assign to the public IP Address of your server.


#3

Thank you! I will try it once I get home.


#4

I set up the no-ip to my public IP address and I get this page when I try to connect out of network. Or am I suppose to use my server’s IP address instead of my public IP?


#5

can you help me through the steps, I cant get it to work.


#6

Using your public IP address is correct. As long as you are using port forwarding on your router and port 80 or port 443 is being forwarded to the private IP address of the server (recommend using port 443 (https)). Is your install of owncloud accessible using https?
The page above is looks like it is the default ‘http:’ page on port 80 and is serving the files at /var/www/html/ . Where is your owncloud directory?

Do you access your owncloud internally using http://xxx.xxx.xxx.x/owncloud? Or https://xxx.xxx.xxx.x/owncloud?


#7

I port forwarded 443 already on my router but when i check with port testing website (https://www.yougetsignal.com/tools/open-ports/) it looks to be closed. Only port 22 and 80 are enable.
My directory is at /var/www/owncloud/
I can only access internally using http (80)


#8

01


#9

More than likely, you don’t have your Apache configuration setup correctly to support 443. Check the file at /etc/apache/sites-enabled/

You should have two files there. One of them is the 000-default.conf and the other should be default-ssl.conf

If not and you only have one, you will need to work on the apache configuration for port 443 (https).

Also, on the confguration file 000-default.conf file, change the line 'DocumentRoot /var/www/html" to read /var/www/owncloud. Then restart the apache service using this command as root ‘service apache2 reload’ The new configuration file will be read and your owncloud directory will be served to the public instead of the default page you posted earlier. IMPORTANT: Owncloud should be run using secured connect HTTPS

Once you have it working through the router correctly on port 80 (http), you can then work on the SSL configuration.


#11

my directory is /etc/apache2/conf-available
no other directory under apache2 and the only file I can find is php7.0-fpm.conf.

I will follow this doc from owncloud: https://doc.owncloud.org/server/latest/admin_manual/installation/letsencrypt/apache.html


#12

Hey, i’m not sure if following an Apache tutorial on a system where lighttpd is running / used is a good idea.

Maybe you can change your setup to Apache so you can use one of the many Apache tutorials available on the net on how to setup this?


#13

Agreed.

Also, what operating system are you using? Also, you can find additional configuration files under /etc/lighthttpd/conf-available. See the information in the default web page in your first post.

Sorry, I didn’t catch that you were running lighthttpd. Install full apache2. There are so many configurations templates, and steps by steps for both apache2 and letsencrypt.


#14

OS: Dietpi
using Lighttpd