Jump to content

Developing a standalone embystat server


reggi

Recommended Posts

Did you see post 11 and 12?  :)

 

No :)  I think a trick is being missed here, though, as surely taking the open source code of Tautulli and modifying for emby would be easier than trying to write something from scratch?

 

That said, I couldn't do it!

Edited by adrianwi
Link to comment
Share on other sites

@

Thanks for wanting to help me with the development. But because you speak of the moviesPage.html I presume you have opened the "statistics" plugin repo. If you want to help out with the EmbyStat server development you need the following repo: https://github.com/mregni/EmbyStat 

I will not update the statistics plugin myself because the development of EmbyStat will have my priority now.

 

If you want to help me with EmbyStat send me a PM and I will explain a bit the work I have done so far. I'm intended to add indeed a lot of stats and details for the people (actors, writers, directors). Can you explain a bit to me what you mean with "Ultimately, I'd like to have a "tag cloud""

 

@@Luke

Thanks for the support, I'll let you know when I'm missing an API call. But for now, the existing API looks good to me. I do intend to create an "EmbyStat plugin" as well for Emby so I can track all events (start media, stop, add user, update, shutdown, ...). If you have a better idea to track these events I'll be more then happy to listen.

 

@@adrianwi

I did have a look at the Tautulli software. But since I'm not a Python developer and the database structure of Emby is totally different I prefer to start with a clean project and start my way to a full-blown statistics server. This will take longer to develop the first release but will be better in the long run. If you do have some ideas for the UI please feel free to comment because I'm not a designer myself :) Check post 15 for some screens.

  • Like 1
Link to comment
Share on other sites

Thanks for posting this.  I've had a look and whilst it has some way to go to show the information Tautulli (aka PlexPy) provides, it's a good start.

 

Will be watching both with interest...

Link to comment
Share on other sites

If you guys want to let those developers know that i can help with whatever api support they need, that would be great. Thanks.

  • Like 1
Link to comment
Share on other sites

Thanks for the link! I contacted the guy, making two systems is maybe a waste of time instead of building one together. 

 

Anyway, I do have a first version you guys can test out. It is really still in alpha phase (you have been warned).

You can find the code at https://github.com/mregni/EmbyStat

 

If you want to run it you can do so by running this docker image: docker run -p <port>:80 uping/embystat:latest-win

At the moment only for windows, but I'm creating an Ubuntu server as we speak so I can build a Linux docker image asap.

 

Link to docker hub: https://hub.docker.com/r/uping/embystat/

 

At the moment only static info is displayed. If you run the tool, after finishing the wizard, go to Tasks and run the movie sync task. 

When this is finished go to movies and you will see some stats about them (the graph you see is just test data, sorry about that)

 

if you find a bug, feel free to create a GitHub issue for it, or post it here in the forum.

Edited by reggi
  • Like 1
Link to comment
Share on other sites

PenkethBoy

so there is only a docker version - no windows version to test?

Link to comment
Share on other sites

There is a windows version to test, but you need dotnet installed or a IIS (express) server.

Problem with running it with Kestrel is that it will keep a very ugly command prompt open. So I do prefer running it in IIS. Just don't forget if running in IIS to set the .NET CLR VERSION of your app pool to "No Managed Code".

 

 

To run in with dotnet open a command window in the folder and run "dotnet EmbyStat.Web.dll". At the moment it will run on port 5000, haven't been able to change it with --server-urls parameter for some reason.

I included both x86 and x64

 

I haven't found a way to make a windows installer for a .NET CORE app. But I'm still researching this path!

 

Ow yes, at the moment there is no update system implemented. So when there is an update later on, the database will be cleared with your statistics. This also is on my high priority list!

win10-x64.zip

win10-x86.zip

Link to comment
Share on other sites

PenkethBoy

@@reggi ok thanks

 

how do you tell it which emby server to get info from (not tried to run it yet) as i have 3 live at the moment?

Link to comment
Share on other sites

When you first start the server it will run a wizard. There you can specify the ur, username, and password for your Emby connection. 

The password itself will not be saved anywhere, it's just needed to get an authentication token from Emby.

Edited by reggi
Link to comment
Share on other sites

If you guys want to let those developers know that i can help with whatever api support they need, that would be great. Thanks.

I had messaged the guy on Reddit and actually told him exactly that you were more than willing to help with any API and linked him to this thread.

 

Hopefully some good will come out of it

  • Like 1
Link to comment
Share on other sites

  • 1 month later...

@@jaketame

 

I had to stop the development for 2 weeks, but next week I will start working on the project again.

At this moment, I have the basic movies and shows stats included in the statistics server. Next steps are getting all useful events from Emby (over WebSocket) and make stats about that data.

But the biggest issue at the moment is that I don't have an update framework in the server. I will need to create that first before starting some beta tests. 

 

I'll keep you all posted when I get the updating working!

  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...
darkassassin07

@@reggi I think u should chance the default port(5000), then the same port is being used by https://ombi.io

If this server/app is using the same port as ombi, they wont be able to co-exist on the same system as you can't bind two apps to to the same port.

Do you mean change the port to something else because ombi uses the same port already? (im not familiar with ombi)

Link to comment
Share on other sites

LIke @@darkassassin07 said, I'm not going to take the same port as Ombi since users will not be able to run both servers on the same machine. 

In the end, I want to make the port changeable in config, but I'm not there yet!

 

I will upload a new Beta version this evening and post a changelog asap as well. A lot has changed since the last update, sorry it took me some time.

There will be no updating logic yet, so when a new release is pushed you will have to remove this version and install the new one (and you will lose your data).

Link to comment
Share on other sites

i know that 2 programs can't run on the same port.. that why i say (you should change default port to something else) then i run EmbyStat.Web.exe it run on port 5000. just like ombi, så i can't run both at the same time

Link to comment
Share on other sites

Haaa ok ok, you can always run the docker image and pick your own port.

Or there is a command option so you can pick your own port number for a dotnet app. I will look into that and give you an update when I have found it.

Link to comment
Share on other sites

Hey guys,

 

So I just pushed a new version to my beta branch, you can find all release files here https://github.com/mregni/EmbyStat/releases or just get them with docker tags beta-linux and beta-win.

Feel free to test it, give feedback here or create issues on the github repo.

 

Some changes that are done:

  • Movie stats added
  • Show stats added
  • Added support for missing episodes (TVDB)
  • Downloadable log files
  • Rework "Movie sync" task to "Media sync" task
  • Expanded settings page with tabs
  • Using database caching system for statistics
  • Added task feedback on task page

This is still a basic version, so no update mechanism is included (meaning that with a new version you will have to remove this one completely first). I'm still working on an updater!

I already did some work to get life events from Emby, but I will first fig all bugs that I have on my backlog before creating new features.

 

If you have any design ideas, new features feel free to post here or create a new github issue. So I can keep track of all useful ideas.

 

I hope you guys like it so far!

  • Like 3
Link to comment
Share on other sites

@@reggi

 

You will need to update all urls with the "/index.html#!/" change in current beta that will be stable released any day now.

 

https://emby.media/community/index.php?/topic/59971-34116-change-the-default-local-address-windows-server/?hl=index.html%23%26%2333%3B

Edited by Happy2Play
  • Like 1
Link to comment
Share on other sites

@Happy2Play 

 

Thanks, forgot about that!

 

EDIT (to prevent double post)

 

I made an account on crowdin for the translations. Feel free to translate the app in your language here: https://crowdin.com/project/embystat

At this moment there are some standard languages included in the app, if your language is not there and you want EmbyStat in your language, PM me and I will add the language for you.

 

Also not sure if it makes sense to divide en-us and en-uk, let me know if I have to! Feel free to also check my English since it's not that perfect :P 

Edited by reggi
Link to comment
Share on other sites

@candyman 

 

I do prefer a github issue. But if you don't have a github account you can post them here yes.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...