DELFI TV

echo "=== DELFI TV PROXY TAISYMAS ===" mkdir -p /root/nginx-backups BACKUP="/root/nginx-backups/lt-tv-radio-before-delfi-$(date +%Y%m%d-%H%M%S).conf" cp -a /etc/nginx/sites-enabled/lt-tv-radio.conf "$BACKUP" echo "Nginx kopija: $BACKUP" python3 - <<'PY' from pathlib import Path path = Path("/etc/nginx/sites-enabled/lt-tv-radio.conf") text = path.read_text(encoding="utf-8") start = text.find("location /delfi-hls/ {") if start < 0: raise SystemExit("KLAIDA: nerastas location /delfi-hls/ blokas") brace = text.find("{", start) depth = 0 end = None for position in range(brace, len(text)): if text[position] == "{": depth += 1 elif text[position] == "}": depth -= 1 if depth == 0: end = position + 1 break if end is None: raise SystemExit("KLAIDA: nerasta DELFI bloko pabaiga") block = text[start:end] lines_to_add = [] if "proxy_set_header Referer" not in block: lines_to_add.append(' proxy_set_header Referer "";') if "proxy_set_header Origin" not in block: lines_to_add.append(' proxy_set_header Origin "";') if lines_to_add: anchor = " proxy_set_header User-Agent" position = block.find(anchor) if position < 0: raise SystemExit("KLAIDA: nerasta User-Agent eilutė") line_end = block.find("n", position) addition = "n" + "n".join(lines_to_add) block = block[:line_end] + addition + block[line_end:] text = text[:start] + block + text[end:] path.write_text(text, encoding="utf-8") print("DELFI proxy antraštės sutvarkytos") PY echo echo "=== NGINX PATIKRA ===" if nginx -t then systemctl reload nginx echo "Nginx sėkmingai perkrautas" else cp -a "$BACKUP" /etc/nginx/sites-enabled/lt-tv-radio.conf echo "KLAIDA: grąžinta atsarginė kopija" exit 1 fi echo echo "=== GROTUVO ADRESO PAKEITIMAS ===" cp -a /opt/lt-tv-radio/delfi-tv-player.html "/root/nginx-backups/delfi-tv-player-before-v5-$(date +%Y%m%d-%H%M%S).html" python3 - <<'PY' from pathlib import Path path = Path("/opt/lt-tv-radio/delfi-tv-player.html") text = path.read_text(encoding="utf-8") old = "https://s1.dcdn.lt/live/televizija/playlist.m3u8" new = "/tv/delfi-hls/playlist.m3u8" if old not in text: raise SystemExit("KLAIDA: grotuve nerastas senasis DELFI adresas") text = text.replace(old, new) path.write_text(text, encoding="utf-8") print("Grotuvas nukreiptas per vietinį DELFI proxy") PY echo echo "=== REZULTATO PATIKRA ===" grep -nE 'proxy_set_header (Referer|Origin)|playlist.m3u8' /etc/nginx/sites-enabled/lt-tv-radio.conf /opt/lt-tv-radio/delfi-tv-player.html curl -sS -H 'Referer: https://lietuvoskameros.lt/' -o /tmp/delfi-playlist.m3u8 -w 'Manifestas: HTTP %{http_code} | %{content_type} | %{size_download} baitųn' https://tiesiogiai.kameros.com/tv/delfi-hls/playlist.m3u8 head -n 5 /tmp/delfi-playlist.m3u8
Another TV channel tv6
Other TV channels
Views
Over the entire period
Share
Share live views with your loved ones!
Support Lithuania’s live cameras

Your support helps keep the cameras running and the website updated.

Support via Contribee

Other TV channels

Discover more TV channels.