
Shoutcast is a media streaming service that lets you create your own media streaming platform. It supports digital audio content in MP3 and Advanced Audio Coding (AAC) formats. This guide explains how to set up a Shoutcast server on Ubuntu and secure it with a Let's Encrypt SSL using Certbot.
Download Shoutcast Distributed Network Audio Server (DNAS) for Linux.
Please see the Shoutcast DNAS download page for the latest Shoutcast DNAS version.
Create a new folder for your Shoutcast server.
Extract the downloaded Shoutcast DNAS to the new folder.
Change the directory to the new folder.
By default, Shoutcast uses port 8000 for source and client connections and port 8001 for legacy source connections, so you need to allow ports 8000 and 8001 on the firewall.
When you run Shoutcast on a normal SSH session, the Shoutcast process closes when you exit the SSH Session. To continuously run Shoutcast even when you leave the SSH session, use tmux, a terminal multiplexer. To create a tmux session, run:
You can change shoutcast with any session name you prefer. Please see How to Install and Use Tmux for more information.
Run the setup.sh script to start the server and proceed with the setup.
Log in to your Shoutcast account and navigate to your radio station's Advanced Settings, then save your radio station's Authhash. You will need this later when you configure your stream.
In your browser, navigate port 8000 at your server's IP address. For example: http://192.0.1.2:8000
On the setup's Stage 1 - Core Settings, Fill in your preferred Source Password and Admin Password. Leave the User Id and License Id text fields blank, and leave the server port by default 8000. Set the maximum number of listeners allowed to connect to your server, then click Continue to proceed with the setup.
On the setup's Stage 2 - Stream Settings, set the number of streams you want to pre-configure. Set each stream's Source Password, Admin Password, the maximum number of listeners allowed to connect to your stream, and your radio station's Authhash that you saved in step 8, then click Continue to proceed with the setup.
On the setup's Stage 3 - Confirm Settings, verify the information you entered in the previous stages, then click Continue to proceed with the setup. Please take note of your stream's Source Password because you will need it when you set up your stream's source later.
On Setup Stage 4 - Save Settings, click Run Server. It redirects you to http://127.0.0.1:8000/admin.cgi?sid=0&pass=YourAdminPass. Replace 127.0.0.1 with your server's IP address and YourAdminPass with the Admin Password you entered on Stage 1 - Core Settings.
Detach from the tmux session by pressing Ctrl + B then D.
Install Nginx.
Create a new Nginx configuration file for your Shoutcast server.
Paste this to your shoutcast.conf file. Replace example.com with your domain name.
Save and exit the file.
Test the Nginx configuration.
Restart Nginx.
Allow the HTTP Port 80 and the HTTPS Port 443 on the firewall.
Install Certbot.
Request a new Let's Encrypt SSL Certificate using Certbot. Replace example.com with your domain name.
Let's Encrypt Certificates are only valid for 90 days. To automatically renew the SSL certificates, add a new cron job.
Select your preferred editor, then paste this into the crontab file.
This command runs at midnight on every first day of the month. It checks if the certificate expires within the next 30 days and renews it if so.
Save and exit the crontab file.
On your browser, navigate to your domain name. Log in to the server using admin as the username and the Admin Password you entered at Stage 1 - Core Settings as the password.
8000 on the Port field. Leave the Mount and Login fields blank, and enter your Stream's Source Password on the Password field.To learn more about Shoutcast, please see these resources:
0 Comments
Be the first to comment and share your perspective with the community.