How to Stream IPTV with ViniPlay + M3U

NATVPS.id – IPTV (Internet Protocol Television) is a technology that broadcasts television, video and live content over an internet network, rather than through traditional antenna cables or satellites. IPTV provides the flexibility to watch on-demand shows, live broadcasts, and other content on various devices with an internet connection.

To view IPTV broadcasts, you can use various media player which supports IPV stream via M3U. One of player that can be used is ViniPlay. ViniPlay is a self-hosted IPTV player with an elegant appearance, enabling high performance flow with IPTV.

This article discusses the steps for installing ViniPlay on a NAT VPS using Docker Compose, along with NGINX configuration for reverse proxy. This article uses Ubuntu 22.04 as a reference, but you can use other distributions such as Debian and CentOS.

Port Forwarding Configuration

Considering we are using NAT, we need to add 2 port forwarding configurations on the Virtualizor panel (or other VPS panel according to provider), ie HTTP and HTTPS port forwarding for the ViniPlay domain.

For example, this article will use domains iptv.tutorial.mdinata.my.id to access ViniPlay. You are free to change the domain according to your choice. Note this domain, because we will use it again in the installation process.

Don’t forget to add a DNS record that goes to your VPS’ NAT public IP, like this:

If you are confused, please read our article regarding domain forwarding here: Explanation of Domain Forwarding in NAT VPS.

Install Docker

We will use Docker and Docker Compose for spread Play Vin.

First, Install curly using the command:

apt update && apt install curl -y

Then, run it script automatic installation of Docker by entering:

curl -fsSL get.docker.com | sh

Wait until the installation process is complete.

Install ViniPlay

First, create a new directory for ViniPlay:

mkdir /opt/viniplay
cd /opt/viniplay

Then, create a Docker Compose file:

apt install nano -y # Jika belum
nano docker-compose.yml

Fill in the following configuration:

services:
  viniplay:
    image: ardovini/viniplay:latest
    container_name: viniplay
    ports:
      - "8998:8998"
    restart: unless-stopped
    volumes:
      - ./viniplay-data:/data
    env_file:
      - ./.env

Save the file with Ctrl-X, yThen Enter.

Then, create the file .env which contain session secretuse one line command:

echo "SESSION_SECRET=$(openssl rand -hex 32)" > .env

Finally, run ViniPlay:

docker compose up -d

Wait for the process spread finished. The first deployment may take a few minutes due to downloading picture Play Vin.

NGINX (Reverse Proxy) Configuration

ViniPlay requires an encrypted connection using HTTPS for security password which is saved. So that we can access URLs with HTTPS via domains such as https://iptv.tutorial.mdinata.my.idwe can use reverse proxy like NGINX.

First, install NGINX via command:

# Hapus Apache2 dan pendukungnya (biasanya terpasang secara bawaan di VPS OpenVZ)
apt purge apache2* -y

# Install NGINX
apt install nginx -y

Create a new host configuration specifically for ViniPlay:

nano /etc/nginx/sites-available/viniplay

Then paste the following configuration:

# 

server {
    listen 80;
    listen [::]:80;
    server_name iptv.tutorial.mdinata.my.id;

    location / {
        proxy_pass 

        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
    }
}

Change viniplay.tutorial.mdinata.my.id with your domain.

Activate the configuration by:

ln -sf /etc/nginx/sites-available/viniplay /etc/nginx/sites-enabled/

# Restart NGINX
systemctl restart nginx

Generate SSL Certificate (Let’s Encrypt)

In order for our domain to be accessible via HTTPS, we need to create an SSL certificate. We can use a free SSL certificate from Let’s Encrypt via Certbot.

Install Certbot and its NGINX plugin use the command:

apt install python3-certbot python3-certbot-nginx

So, produce certificate via Certbot with command

certbot --nginx -d iptv.tutorial.mdinata.my.id

Change iptv.tutorial.mdinata.my.id with your domain.

Happy! ViniPlay can currently be accessed via a secure HTTPS connection.

Accessing ViniPlay

ViniPlay can be accessed via your previous domain. Example:

If you have already created an account, you will be directed to dashboard.

Cover

That’s it for this article about the steps to install ViniPlay on a NAT VPS.

If you are confused or in doubt, don’t hesitate to ask in the Telegram group @IPv6Indonesia. Thank You!

News
Berita Teknologi
Berita Olahraga
Sports news
sports
Motivation
football prediction
technology
Berita Technologi
Berita Terkini
Tempat Wisata
News Flash
Football
Gaming
Game News
Gamers
Jasa Artikel
Jasa Backlink
Agen234
Agen234
Agen234
Resep
Download Film

Gaming center adalah sebuah tempat atau fasilitas yang menyediakan berbagai perangkat dan layanan untuk bermain video game, baik di PC, konsol, maupun mesin arcade. Gaming center ini bisa dikunjungi oleh siapa saja yang ingin bermain game secara individu atau bersama teman-teman. Beberapa gaming center juga sering digunakan sebagai lokasi turnamen game atau esports.