Updated: Mar 28
What is Cloud?
"The cloud" refers to servers that are accessed over the Internet, and the software and databases that run on those servers. Cloud servers are located in data centers all over the world. By using cloud computing, users and companies do not have to manage physical servers themselves or run software applications on their own machines.flares definition:
What is Cloudron?
Cloudron is a cloud application platform that allows you to create applications with only one click. Their 80+ stable apps have been thoroughly tested and approved for trouble-free operation. It automates everything from database configuration and DNS record setup to certificate installation and management. Cloudron provides a centralized platform for managing users and online apps from the convenience of your web browser.
Cloudron have a Application called Guacamole, Which is perfect solution for over problem.
We need a program that can run VMs on a webside. Thats exactly what Guacamole does.
Famous Guacamole users are Tryhackme.com
Guacamole is a clientless remote desktop gateway developed by Apache. Standard protocols such as VNC, RDP, and SSH are supported.
It's called clientless since it doesn't require any plugins or client software.
Once Guacamole is deployed on a server, all you need is a web browser to access your desktops.
**Note: You dont need Cloudron to install Guacamole. I use Guacamole in cloudron as its much easier to control in case anything happens. and at the same time Cloudron automates updates any software thats included with cloudron.
So, how may Cloudron assist me in my work?
The following are the most crucial aspects to remember:
Cloudron manages updates and provides a one-click restore option to maintain maximum uptime. It also announces new software and server releases, as well as security updates that will be available through the Cloudron App Store.
Cloudron automates a variety of tasks, such as database configuration, DNS setup, SSL installation, and so on. Choose an app you'd want to install, click it, and Cloudron will take care of the rest.
Using a web browser, you can manage all of your applications and users! The management is far more pleasurable than you could have thought thanks to a user-friendly and straightforward interface.
According to Cloudron:
"Cloudron requires at least 1GB RAM, 20GB Disk space. Make sure the firewall does not block port 80 (http) and 443 (https). Cloudron does not support running on ARM, LXC, Docker or OpenVZ."
Whats needed to make cloudron work on LocalServer?
A Linux Machine
A router with Portforwarding Possibility
Installing Linux Machine is relatively easy. I used Proxmox server to install ubuntu for this process.
If you want to learn how to install proxmox first Just follow this link to go through installation
Provide a domain like example.com. The way Cloudron works is that the dashboard gets installed at my.example.com, and apps are installed under subdomains that you specify like git.example.com, chat.example.com, and so on.
It is perfectly safe to use a domain that is already in use as long as the "my subdomain is available. When installing apps, Cloudron will never overwrite your existing DNS records and your existing subdomains will remain intact. It is also possible to use a subdomain like cloudron.example.com.
Next, select the DNS service in which the domain in hosted. If your service is not listed below, use the Wildcard or Manual option.
Google Cloud DNS
There isnt any requirement that your domain should be a ".com". You can buy a cheap domain from Freenom .
Just follow on screen instructions.
These domains are totaly free. but These domains create problem when connecting cloudron server to cloudflare. Later in this Project i will show how to overcome that problem.
Setting up Cloudflare:
Guidance Copied from Cloudflare.com
Click on +Add site on the top right corner.
Enter your website’s root domain and then click Add Site. For example, if your website is www.example.com, type example.com. and select free plan,.
Cloudflare attempts to automatically identify your DNS records. This process takes approximately 60 seconds to complete.
Click Confirm in the Confirm Plan window that appears.
Review whether all DNS records were identified in the DNS query results window.
Manually add missing DNS records
Decide which subdomains enable Cloudflare security and performance features or bypass Cloudflare.security and performance features or bypass Cloudflare
Copy the 2 Cloudflare nameservers displayed and click Continue.
To finish domain setup and activate your domain on Cloudflare, change your domain nameservers to Cloudflare.
If you like to follow Complete guidance with pictures Follow this guidance.
What is port forwarding?
Port forwarding configures your network to host public services such as web servers, FTP servers, e-mail servers, and other specialized Internet applications. When users submit this sort of request to your network through the Internet, the router routes it to the proper machine.
How to setup port forwarding?
This guidance is very dependant on what router you are using. so find your router name and change its port forwarding rules. If your router have firewall, you have to add rules inside your firewall too.
I use Pfsense. Thats how it should look like in portward settings. Its a best practice to use a router that can deal with firewall and portwarding and also IPS. When you open your network for any port. You are opening your network to unnecessary risk. So best to have Firewall, IPS and then think about port forwading.
remember to put portwarding on top. if you have a setup where you have deny on top it will block everything. Most of firewall do have expeclit deny function automatically activated. This means if you dont open anything firewall will block everything.
Download the Cloudron setup script using wget. # wget https://cloudron.io/cloudron-setup
Make the script executable. # chmod +x ./cloudron-setup
Install Cloudron by running the script. # bash cloudron-setup
The installation script will take between 5-7 minutes to complete. Once ready, you will be prompted to reboot the server, enter Y to restart.
############################################## Cloudron Setup (latest) ############################################## Follow setup logs in a second terminal with: $ tail -f /var/log/cloudron-setup.log Join us at https://forum.cloudron.io for any questions. => Updating apt and installing script dependencies => Checking version => Downloading version 7.0.4 ... => Installing base dependencies and downloading docker images (this takes some time) ... => Installing version 7.0.4 (this takes some time) ... => Waiting for cloudron to be ready (this takes some time) ....
It's time to configure Cloudron now that it's been successfully installed on your server.
Visit your server's IP address or associated domain name in a web browser and add a browser exception to accept the self-signed certificate. http://YOUR_SERVER_IP_ADDRESS OR http://example.com
If you didnt buy your service from any of these listed below, then you have to move your website to cloudlfare as you need to use the Wildcard or Manual option. Which takes extra time. and sometimes makes trouble with not so known DNS providers.
select the DNS service in which the domain in hosted.
Google Cloud DNS
To get started:
Choose the Edit zone DNS template to create a token.
When using the API token, it must include the Zone:Read and DNS:Edit permission. The token only needs permission for the specific zone as shown below:
You have to add global API key to make cloudron connection to cloudflare.
At this stage you get problem with registration of domain if you didnt buy "dotcom" or domain from welknown vendors.
You have to add it manually. Its not difficult. This takes just extra time.
Then again problem arises when your IP address changes. In Private houses we often have a Dynamic IP address. Which means we cant have a fixed IP address. This causes a problem when you run a website. Whenever you restarts your Router you have to manually update your IP address.
Cloudflare needs a constant connection to IP address of webserver, but as we dont have same ip each time we restart router. This creates a issue. Fear not! To solve this we need a program called Dynamic DNS inside pfsense.
If you are confused follow this link. It will explain everything about Dynamic DNS and how to setup.
Cloudron will redirect to https://my.example.com after DNS is configured. A green lock will appear in the address bar of your browser, indicating that the connection to your Cloudron is now safe.
Account in the App Store
You're all set to begin installing applications!
You'll be requested to register a cloudron.io account when you click the App Store link in the UI.
Your subscription and billing will be managed via this account. Cloudron do offer a free plan.
You must first create a Cloudron account before installing applications. Click the Create Account button after entering an email address and a password, reading and accepting the Cloudron license.
The server will register with Cloudron and receive a unique Cloudron ID after signing up.
Apache Guacamole is a clientless remote desktop gateway. It supports standard protocols like VNC, RDP, and SSH.
Search for Guacamole
Note: remember to add "guac" in you dns if you didnt bought your domain from well known seller or well known domains.
If you used API key. This step will be fixed automatically.
Go to MyApps
Click on Guac
Note: default username and password is guacadmin
Without Any connections
You need to add VMs to create a remote connection.
Adding Connections to Guacamole:
Click on Username "Guacadmin"
Click on settings
Connections -> New Connections
Add Connection details
Note: Username and password are login credentials you have on that particual machine. for Windows best to use RDP and Linux you can use VNC. remember to activate VNC on that particular VM.
Save connection settings.
Open Guacadmin>Home> Click on Newly created Connection.
Now you have a running VM in cloud. IT can be accessed from anywhere in the world.
Cloudron provides a centralized way to manage users and specify which apps they can access. Cloudron has a backup solution that lets you back up and restore each app individually (compared to server snapshots).In this tutorial we only used Guacamole to make Remote VM access possible.