Connect - Bytesized Hosting Wiki
Bytesized Connect
Bytesized Connect is an application control panel that turns your server into a application platform. Simply run the (open-source) Bytesized Connect Daemon (BCD) to plug your server into the Bytesized website. It will enable you to configure all supported apps through our web-interface without having to touch a terminal. Because the daemon is completely open-source you can contribute your own apps as well.
Philosophy
BCD is being developed with the following principles in mind:
- Process isolation - Every application should be self-contained and don't pollute the filesystem.
- Security - No interface from the website to the daemon should require root access.
- Modularity - Connect should be able to run next to any user defined configuration, it should not take over your server completely or require an 'empty' state to be able to be installed.
- Open source - The daemon should always be completely open-source so it can be validated and tweaked. You should never have to run a black box on your server.
Requirements
- Any linux version with support for Docker.
- Root access to install it.
- The automatic installer only works on Ubuntu 14.04, 16.04 or 18.04;
Connect is powered by Docker
Every application you install via BCD is actually installed in a lightweight virtual server called a container. We use Docker to do the management of the containers for use. This means that each application has it's own full filesystem that differs from your host system and only has access to a set amount of ports. Whenever you deal with applications keep this in mind.
General information
If you follow the automatic installer BCD installs a new user called bytesized
. All app activity will be tied to this user. The default structure looks as follows.
/home/bytesized/config - Contains subfolders with all the configuration for each app you install. The filebot configuration files for instance can be found in /home/bytesized/config/filebot
/home/bytesized/data - Contains a completed
and downloading
folder.
/home/bytesized/media - Contains tv
and movies
folder.
There is always a difference between what your apps see and what the filesystem on the host looks like. Most apps have these folders mounted inside of their containers as /config
, /data
and /media
. You can decide during the install of an app what should show up in these folders inside the application container. Filebot is a bit different the whole homefolder is mounted as /host
on the Filebot container.
If you use the default paths then all apps will install correctly without changing any of their setup variables, you are however always free to change them around.
BCD-Proxy
If you use the automatic installer you will also get a daemon running on port 80 and 443 who handles domains for you. By default we create a free domain for you when you install connect: yourname.bysh.io
. You can use this to create pretty URLs like syncthing.yourname.bysh.io
to your applications.
Custom domains
bcd-proxy supports custom domains. If you own your own domains you can set up (sub-)domains based on this domain by adding your own domain by pressing "actions" on your Connect page and selecting domains. Follow the instructions there so you can create routes for your own domains.
(HTTPS) SSL Routes
If you bring your own domain you can also enable https support for your routes. Any routes that are created with your own domains can be reached through https. In the background bcd-proxy will automatically request a ssl certificate for you and enable it. It's using "let's encrypt" behind the scene which do have some rate limits so do know that it might not work if you are using a a lot of apps.
Enabling FTP
There is no external access for the bytesized
user that Connect creates by default. So if you want to have access through a FTP daemon, make sure you (re)set the password using passwd bytesized
. If that still doesn't allow access, make sure the user has an active default shell such as bash. You can try setting that with chsh -s bash bytesized
.
Firewall considerations
BCD users who enable the iptables firewall utility bundled with Ubuntu using either native iptables rules or the 'ufw' utility will find that there are a number of apps that will need a firewall port open to access them from an alternate host or network location if there firewall rules are set to reject/deny all incoming traffic by default.
Currently the rutorrent
and deluge
apps use the Docker host network passthrough mode instead of the default 'bridge'. You will need to add firewall rules to your host that match the web interface and daemon ports you specified or let BCD randomly select when you installed either of these apps.
Port 8112 will need to be open to send status back to Byte-sized hosting.
Allowing specific ports with Ubuntu's "uncomplicated firewall" (ufw)
These instructions assume you already have UFW installed and enabled
- At the command prompt, enter
sudo ufw allow <port number>/tcp
and replace the<port number>
text with the port allocated to the app when you installed it - Next, reload the firewall rules and make your changes active by entering
sudo ufw reload
at the command prompt. - That's all folks.
Allowing specific ports with native iptables rules
These instructions assume you already have iptables enabled at startup of your host
- At the command prompt, enter
sudo iptables -A INPUT -p tcp --dport <port number> -j ACCEPT
and replace the<port number>
text with the port allocated to the app when you installed it - Next, make your changes active and persistent by entering
sudo iptables-save
at the command prompt - You're all done.
Removing Connect
If you would like to remove connect please tell us why you do so first so we can work with that feedback. If you are certain you no longer need to use BCD on your server, you can follow the following steps to remove the BCD service and proxy:
- Remove Docker using
apt-get remove docker
. - Stop the services
service bcd stop
andservice bcd-proxy stop
- Remove the binaries
rm /usr/local/bin/bcd
andrm /usr/local/bin/bcd-proxy
- Remove the service files
rm /lib/systemd/system/bcd.service
andrm /lib/systemd/system/bcd-proxy.service
Last Author | Contributors | Versions | Last update |
---|---|---|---|
Maran | None | 16 | Tue, 09 Mar 2021 18:36:00 +0100 |