Open petrmenzel opened 6 years ago
So there was problem with GoRoot and GoPath. It is solved now.
Hi, glad it's compiling now. What did you do to your GOROOT
and GOPATH
?
I must admit this project is still in development, so it still does not work completely with Plex & I need to figure out why.
For debugging, try accessing http://localhost:8080/lineup.json
in your browser and try opening one of the stream URLs. (e.g. http://localhost:8080/stream/xxxxxxxxx
)
Could be problem, that I have changed inputs (in main.go)?
My step by step installing and using.
# Install programs.
sudo apt-get install golang-go
sudo apt-get install automake
# Set paths.
export GOPATH=/home/myusername/go
export GOROOT=/usr/lib/go-1.9
# Install aditional packages.
sudo go get github.com/gorilla/mux # Is downloaded to /home/myusername/go/src/github.com.
sudo go get github.com/grafov/m3u8 # Is downloaded to /home/myusername/go/src/github.com.
sudo go get github.com/golang/glog # Is downloaded to /home/myusername/go/src/github.com.
cd /usr/lib/go-1.9/github.com
https://github.com/hazcod/muxy
git clone https://github.com/hazcod/muxy # It will be located in /usr/lib/go-1.9/github.com.
cd muxy
sudo make
./muxyProxy http://urlpathto.m3u8 # Set URL to .m3u8 file.
./muxyProxy '/local/path/to/.m3u' # Set path to .m3u8 file.
Useful command to check that you have correctly set GoPath and GoRoot: go env
I have run the ./muxyProxy
Added to my browser http://192.168.1.200:8880/lineup.json
--> get list of something like this:
[{"GuideName":"T1","GuideNumber":"0.0","URL":"http://192.168.1.200:8880/stream/VERYLONGHASH=="}, {next channel}, {...}, {...}]
http://192.168.1.200:8880/stream/VERYLONGHASH==
run nothing in Google Chrome HTTP ERROR 500
in bash:
/Resources/playlist.m3u' E0131 13:07:33.551519 32219 streamer.go:40] Could not fetch channel playlist: Could not get channel playlist: unknown m3u type: E0131 13:07:33.653300 32219 streamer.go:40] Could not fetch channel playlist: Could not get channel playlist: unknown m3u type: E0131 13:07:33.784305 32219 streamer.go:40] Could not fetch channel playlist: Could not get channel playlist: unknown m3u type:
So the error could be this:
unknown m3u type
That's because the parser only accepts m3u8 files, do you have the possibility to get a m3u8
instead of m3u
?
I will try change output extension from script from .m3u to .m3u8 and I will see.
I was able to generate m3u8 file. But still "unknown type". Could you send me example of your working .m3u8 structure of the file? Thx you very much.
My structure:
#EXTM3U
#EXTINF:0 tvg-id="ct1hd" tvg-name="ČT1" tvg-logo="ct1hd.png" group-title="General",ČT1
http://media.kuki.cz:8116/ct1hd/stream.m3u8?type=live&sign=hash&expires=1517454001
Afraid not, I have a m3u8 for my paid subscription.
Me too, but I need only structure to try make same.
I have minimalized the M3U8 file to this format:
#EXTM3U8
#EXTINF:0,CT1
url_of_the_stream
#EXTINF:0,CT2
url_of_the_stream
#EXTINF:0,CT24
url_of_the_stream
console log after tried to play in VLC
I0131 15:39:59.001144 5736 endpoint.go:119] 192.168.1.2:5639 GET /stream/aHR0cDovL21lZGlhLmt1a2kuY3o6ODExNi9jdDFoZC9zdHJlYW0ubTN1OD90eXBlPWxpdmUmc2lnbj03OFVUckNGeWNoR1JuV0htcm9xd3l3JmV4cGlyZXM9MTUxNzQ4ODA2Ng
E0131 15:39:59.001219 5736 endpoint.go:47] Could not decode stream URI: aHR0cDovL21lZGlhLmt1a2kuY3o6ODExNi9jdDFoZC9zdHJlYW0ubTN1OD90eXBlPWxpdmUmc2lnbj03OFVUckNGeWNoR1JuV0htcm9xd3l3JmV4cGlyZXM9MTUxNzQ4ODA2Ng
I0131 15:39:59.001238 5736 endpoint.go:14] Sending errorcode: 500
There will be problem with the type of the stream url. But not with the m3u8 structure. The app works for .M3U8 same as for .M3U.
Correct structure for IPTV for MUXY should be this (nothing more):
#EXTINF:-1,channel_name_1
url_of_the_stream_1
#EXTINF:-1,channel_name_2
url_of_the_stream_2
#EXTINF:-1,channel_name_X
url_of_the_stream_X
I have tried public .m3u where are links in this types url_to_strem.ts
but my type is stream.m3u8?type=live&sign=hash&expires=1517488066
I have also tested that the app works in same way for LOCAL stored .m3u and for URL stored .m3u.
Both of them url_to_strem.ts
and stream.m3u8?type=live&sign=hash&expires=1517488066
work perfectly in VLC.
But after converting by app to the http://ip_adress:port/stream/long_hash
happens this:
stream.m3u8?type=live&sign=hash&expires=1517488066
→ unknown m3u type
(Does not play anything in the VLC)url_to_strem.ts
→ Reading line error: EOF
(But in the VLC I can hear some "noise".)
I have stuck on this:
non-standard import "github.com/golang/glog" in standard package "muxy/muxy"
As I found from Go version 1.8 I do not need set up GoRoot and GoPath. I know that it is problem that I do not know how "go" works. But can you give me a little bit direction how to build this awesome tool? :-)
Machine: Ubuntu 16.04.3 LTS
I have done this:
make
But I have received error above.Thx you very much