In this tutorial, we will walk through the steps to install Owncast on an Ubuntu Server. Owncast is a free, open-source live video streaming server that you can self-host on your own server or cloud instance.
We first need to install a few dependencies, including Go and FFmpeg:
sudo apt-get update
sudo apt-get install build-essential libssl-dev curl unzip ffmpeg
Additionally, if you want to use Owncast's built-in web player, you'll also need to install Node.js and NPM:
sudo apt-get install nodejs npm
We will now download and install Owncast. Go to Owncast's GitHub repository and look for the "latest release" tag. In our case, at the time of writing, the latest release was 0.0.9
.
Download the latest release to your server.
curl -L https://github.com/owncast/owncast/archive/v0.0.9.zip -o owncast.zip
Extract the contents of the ZIP file using the unzip
command:
unzip owncast.zip -d owncast
Move into the extracted directory using the command cd owncast/owncast-0.0.9
.
Run the go build
command to compile Owncast.
go build
Before running Owncast, we must configure it according to our needs. The configuration file is located in config.yaml
. To edit the configuration file, we recommend using the nano
text editor.
nano config.yaml
Edit the baseURL
field in the configuration file with your domain name or subdomain.
baseURL: "https://example.com"
If you want to use an SSL/TLS certificate, adjust the https
field accordingly:
# If you would like to use HTTPS uncomment and fill in the parameters below
# Note that these values can be empty string to not use HTTPS.
# cert: "/path/to/your/cert.pem"
# key: "/path/to/your/key.pem"
Replace /path/to/your/cert.pem
and /path/to/your/key.pem
with the path to your SSL/TLS certificate and private key, respectively.
You can now run Owncast on your server. In the same directory where Owncast was built, run the following command:
./owncast
Your terminal window will display a message like the one below which tells us Owncast is now running.
🌱 Owncast is starting up
🔗 HTTPS Enabled: true
🭕️ HLS Enabled: true
🚀 dvr.Enabled: true
🍿Stream title: Untitled
〽️Maximum viewer count (0 for no limit): 0
👀 Viewer metrics enabled: false
🎆Webhook endpoint URL:
⏰Stream start time: 2021-10-18 15:40:20.0410616 +0000 UTC
🌊Stream finished, normally ending Owncast..
Go to your web browser and access Owncast's URL, which should be https://your-domain-or-subdomain.com/
. If you configured SSL/TLS, your web browser should show the padlock indicating that the connection is secure.
You may see a default Owncast page, but you can customize the page by editing the noStreamHTML
field in the configuration file.
We have successfully installed Owncast on an Ubuntu server and configured it to use our own domain or subdomain, and SSL/TLS certificate. You can now use Owncast to self-host live video streaming for your audience.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!