Update readme

This commit is contained in:
Zoe Roux 2023-04-04 23:13:29 +09:00
parent 3b98263fbc
commit e9f9ae5154
14 changed files with 44 additions and 329 deletions

View File

@ -11,7 +11,6 @@ KYOO_APIKEYS=t7H5!@4iMNsAaSJQ49pat4jprJgTcF656if#J3
DEFAULT_PERMISSIONS=overall.read DEFAULT_PERMISSIONS=overall.read
UNLOGGED_PERMISSIONS=overall.read UNLOGGED_PERMISSIONS=overall.read
TVDB__APIKEY=
THEMOVIEDB_APIKEY= THEMOVIEDB_APIKEY=
PUBLIC_BACK_URL=http://localhost:5000 PUBLIC_BACK_URL=http://localhost:5000

View File

@ -1,33 +0,0 @@
name: Documentation
on:
push:
branches:
- master
jobs:
doc:
name: Update the documentation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: nikeee/docfx-action@v1.0.0
name: Build Documentation
with:
args: docs/docfx.json
- name: Update the docs
run: |
cd docs/_site
sudo chown $(whoami):$(whoami) . -R
echo -n docs.kyoo.moe > CNAME
git config --global user.email "${GITHUB_ACTOR}@github.com"
git config --global user.name "${GITHUB_ACTOR}"
git init
git add -A
git commit -m "Deploying the documentation"
git remote add origin https://${GITHUB_ACTOR}:${GITHUB_TOKEN}@${GITHUB_REPO}
git checkout -b gh-pages
git push --force origin gh-pages
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_REPO: "github.com/${{github.repository_owner}}/Kyoo"

43
INSTALLING.md Normal file
View File

@ -0,0 +1,43 @@
# Installing
To install Kyoo, you need docker and docker-compose. Those can be installed from here for
[Linux](https://docs.docker.com/engine/install/)
[Mac](https://docs.docker.com/desktop/install/mac-install/)
or [Windows](https://docs.docker.com/desktop/install/windows-install/). Docker is used to run each services of Kyoo in
an isolated environment with all the dependencies they need.
Kyoo also needs 3 files to work properly. Two of them can simply be copy-pasted from this repository, the other needs to be filled in with your configurations.
Those 3 files are:
- A `docker-compose.yml` (simply copy docker-compose.prod.yml from [here](https://raw.githubusercontent.com/zoriya/Kyoo/master/docker-compose.prod.yml)).
- A `nginx.conf.template` copied from [here](https://raw.githubusercontent.com/zoriya/Kyoo/master/nginx.conf.template).
- A `.env` file that you fill need to fill. Look at the example [.env.example](https://raw.githubusercontent.com/zoriya/Kyoo/master/.env.example)
> If you want an explanation of what are those files, you can read the following:
> The `docker-compose.yml` file describes the different services of Kyoo, where they should be downloaded and their start order. \
> The `nignx.conf.template` file describes which service will be called when accessing the URL of Kyoo. \
> The `.env` file contains all the configuration options that the services in `docker-compose.yml` will read.
To retrieve metadata, Kyoo will need to communicate with an external service. For now, that is `the movie database`.
For this purpose, you will need to get an API Key. For that, go to [themoviedb.org](https://www.themoviedb.org/) and create an account, then
go [here](https://www.themoviedb.org/settings/api) and copy the `API Key (v3 auth)`, paste it after the `THEMOVIEDB_APIKEY=` on the `.env` file.
The next and last step is actually starting Kyoo. To do that, open a terminal in the same directory as the 3 configurations files
and run `docker-compose up -d`.
Congratulation, everything is now ready to use Kyoo. You can navigate to `http://localhost:8901` on a web browser to see your instance of Kyoo.
# Updating
Updating Kyoo is exactly the same as installing it. Get an updated version of the `docker-compose.yml` and `nginx.conf.template` files and
unsure that your `.env` contains all the options specified in the updated `.env.example` file.
After that, you will need to update Kyoo's services. For that, open a terminal in the configuration's directory and run
the command `docker-compose pull`. You are now ready to restart Kyoo, you can run `docker-compose up -d`.
# Uninstalling
To uninstall Kyoo, you need to open a terminal in the configuration's directory and run `docker-compose down`. This will
stop Kyoo's services. You can then remove the configuration files.

View File

@ -1,12 +1,4 @@
# <img width="24px" src="./icons/icon-256x256.png" alt="Kyoo"> Kyoo # <img width="24px" src="./icons/icon-256x256.png" alt="Kyoo"> Kyoo
<p>
<a href="https://github.com/AnonymusRaccoon/Kyoo/actions/workflows/build.yml"><img src="https://img.shields.io/github/workflow/status/AnonymusRaccoon/Kyoo/Build?style=flat-square" alt="Build status"></a>
<a href="https://github.com/AnonymusRaccoon/Kyoo/actions/workflows/tests.yml"><img src="https://img.shields.io/github/workflow/status/AnonymusRaccoon/Kyoo/Testing?label=tests&style=flat-square" alt="Tests status"></a>
<a href="https://github.com/users/AnonymusRaccoon/packages/container/package/kyoo"><img src="https://img.shields.io/github/workflow/status/AnonymusRaccoon/Kyoo/Docker?label=docker&style=flat-square" alt="Docker status"/></a>
<a href="https://sonarcloud.io/dashboard?id=AnonymusRaccoon_Kyoo"><img src="https://img.shields.io/sonar/tests/AnonymusRaccoon_Kyoo?compact_message&server=https%3A%2F%2Fsonarcloud.io&style=flat-square" alt="Test report"></a>
<a href="https://sonarcloud.io/dashboard?id=AnonymusRaccoon_Kyoo"><img src="https://img.shields.io/sonar/coverage/AnonymusRaccoon_Kyoo?server=https%3A%2F%2Fsonarcloud.io&style=flat-square" alt="Coverage"></a>
<a href="./LICENSE"><img src="https://img.shields.io/github/license/AnonymusRaccoon/Kyoo?style=flat-square" alt="License"></a>
</p>
Kyoo is an open-source media browser which allow you to stream your movies, tv-shows or anime. Kyoo is an open-source media browser which allow you to stream your movies, tv-shows or anime.
It is an alternative to Plex, Emby or Jellyfin. It is an alternative to Plex, Emby or Jellyfin.
@ -17,10 +9,8 @@ Feel free to open issues or pull requests, all contribution are welcomed.
## Getting started ## Getting started
- [Installation](https://docs.kyoo.moe/start/install.html) - [Installation](./INSTALLING.md)
- [Setting Up](https://docs.kyoo.moe/start/setting_up.html)
- [Api Documentation](https://demo.kyoo.moe/redoc) - [Api Documentation](https://demo.kyoo.moe/redoc)
- [Documentation (work in progress)](https://docs.kyoo.moe)
- [Contributing](./CONTRIBUTING.md) - [Contributing](./CONTRIBUTING.md)
## Features ## Features
@ -30,53 +20,12 @@ Feel free to open issues or pull requests, all contribution are welcomed.
- Account system with a permission system - Account system with a permission system
- Handle subtitles natively with embedded fonts (ass, subrip or vtt) - Handle subtitles natively with embedded fonts (ass, subrip or vtt)
- Entirely free and works without internet (when metadata have already been downloaded) - Entirely free and works without internet (when metadata have already been downloaded)
- Works on Linux, Windows, Docker and probably Mac
- A powerful plugin system
## Live Demo ## Live Demo
You can see a live demo with copyright-free movies here: [demo.kyoo.moe](https://demo.kyoo.moe). You can see a live demo with copyright-free movies here: [demo.kyoo.moe](https://demo.kyoo.moe).
Thanks to the [blender studio](https://www.blender.org/about/studio/) for providing open-source movies available for all. Thanks to the [blender studio](https://www.blender.org/about/studio/) for providing open-source movies available for all.
The demo server is simply created using the following docker compose:
```yml
version: "3.8"
services:
kyoo:
image: ghcr.io/anonymusraccoon/kyoo:master
restart: on-failure
environment:
- KYOO_DATADIR=/var/lib/kyoo
- DATABASE__ENABLED=postgres
- DATABASE__CONFIGURATIONS__POSTGRES__SERVER=postgres
- DATABASE__CONFIGURATIONS__POSTGRES__USER ID=kyoo
- DATABASE__CONFIGURATIONS__POSTGRES__PASSWORD=kyooPassword
- TVDB__APIKEY=TheTvDbApiKey
- THE-MOVIEDB__APIKEY=TheMovieDbApiKey
ports:
- "80:5000"
depends_on:
- postgres
volumes:
- kyoo:/var/lib/kyoo
- video:/video
postgres:
image: "postgres"
restart: on-failure
environment:
- POSTGRES_USER=kyoo
- POSTGRES_PASSWORD=kyooPassword
volumes:
- db:/var/lib/postgresql/data
volumes:
kyoo:
video:
db:
```
## Screens ## Screens
![Show](../screens/show.png?raw=true) ![Show](../screens/show.png?raw=true)

2
docs/.gitignore vendored
View File

@ -1,2 +0,0 @@
_site/
obj

View File

@ -1,20 +0,0 @@
---
uid: build
title: Build
---
# Build
## Dependencies
To develop for Kyoo, you will need the **.NET 5.0 SDK**, **node** and **npm** for the webapp. If you want to build the transcoder, you will also need a cmake compatible environment.
## Building
To run the development server, simply open the .sln file with your favorite C# IDE (like Jetbrain's Rider or Visual Studio) and press run or you can use the CLI and use the ```dotnet run --project src/Kyoo.Host.Console --launch-profile "Console"``` command.
To pack the application, run the ```dotnet publish -c Release -o <build_path> Kyoo.Host.Console``` command. This will build the server, the webapp and the transcoder and output files in the <build_path> directory.
## Skipping parts
If you want, you can build kyoo without it's transcoder by running ```dotnet build '-p:SkipTranscoder=true'```. You are now responsible of bringing a transcoder dynamic library at the build location. If you don't bring one, the transcoder won't be available.
You can also disable the webapp build by running ```dotnet build '-p:SkipWebApp=true'```. Those two options can be combined by running ```dotnet build '-p:SkipTranscoder=true;SkipWebApp=true'```

View File

@ -1,8 +0,0 @@
---
uid: plugin
title: Plugin
---
# Plugins
You can create plugins for Kyoo. To do that, create a C# Library project targeting the .Net Core 5 and install the [Kyoo.Abstraction](https://www.nuget.org/packages/Kyoo.Abstraction) package and implement the IPlugin interface.

View File

@ -1,2 +0,0 @@
- name: Build
href: build.md

View File

@ -1,65 +0,0 @@
{
"metadata": [
{
"src": [
{
"files": [ "**.csproj" ],
"exclude": [ "**/bin/**", "**/obj/**" ],
"src": "../src"
}
],
"dest": "obj/api",
"disableGitFeatures": false,
"disableDefaultFilter": false
}
],
"build": {
"content": [
{
"files": [
"**/*.md",
"**/toc.yml"
]
},
{
"files": "CONTRIBUTING.md",
"src": "../",
"dest": "contributing"
},
{
"files": [ "**/*.yml" ],
"src": "obj/api",
"dest": "api"
}
],
"resource": [
{
"files": ["icons/**"],
"src": "../"
}
],
"dest": "_site",
"globalMetadata": {
"_appTitle": "Documentation - Kyoo",
"_appLogoPath": "icons/icon.svg",
"_appFaviconPath": "icons/icon-256x256.ico",
"_gitContribute": {
"repo": "https://github.com/AnonymusRaccoon/Kyoo",
"branch": "master",
"apiSpecFolder": "docs"
},
"_enableSearch": true
},
"globalMetadataFiles": [],
"fileMetadataFiles": [],
"template": [
"default"
],
"postProcessors": [],
"markdownEngineName": "markdig",
"noLangKeyword": false,
"keepFileLink": false,
"cleanupCacheHistory": false,
"disableGitFeatures": false
}
}

View File

@ -1,8 +0,0 @@
---
uid: home
title: Home
---
# Welcome to Kyoo's Documentation
This is a work in progress, for now this documentation is mostly empty. The [Rest API](https://demo.kyoo.moe/redoc) is the only part that is well documented.

View File

@ -1,21 +0,0 @@
---
uid: install
title: Install
---
# Installing
To install kyoo, you can use one of the following installer depending on your platform:
- [Arch](https://nightly.link/AnonymusRaccoon/Kyoo/workflows/build/master/kyoo_arch.zip)
- [Debian](https://nightly.link/AnonymusRaccoon/Kyoo/workflows/build/master/kyoo_debian.zip)
- [RPM](https://nightly.link/AnonymusRaccoon/Kyoo/workflows/build/master/kyoo_rpm.zip)
- [Windows](https://nightly.link/AnonymusRaccoon/Kyoo/workflows/build/master/kyoo_windows_installer.zip)
If your system is not on the previous list, you can use one of the prebuild version:
- [Windows](https://nightly.link/AnonymusRaccoon/Kyoo/workflows/build/master/kyoo_windows.zip)
- [MacOS](https://nightly.link/AnonymusRaccoon/Kyoo/workflows/build/master/kyoo_macos.zip)
- [Linux](https://nightly.link/AnonymusRaccoon/Kyoo/workflows/build/master/kyoo_linux.zip)
# Docker
A docker file is also available and an up-to-date docker image is available at: `ghcr.io/anonymusraccoon/kyoo:master`. An example docker-compose image is available at the root of the repository.

View File

@ -1,101 +0,0 @@
---
uid: setting_up
title: Setting Up
---
# Welcome to Kyoo
Hi, and welcome to Kyoo, you are about to embark on this wonderful journey that is media management & streaming
To setup Kyoo, you need to make sure you installed it, then we'll configure some settings, maybe rearrange your files. This shouldn't take long if you are used to manage JSON files, and regex.
## settings.json
If you installed Kyoo on Linux/macOS, their should be a ```/var/lib/Kyoo``` directory
If you are on a Windows, it should be ```C:\ProgramData\Kyoo```
Inside this folder, we'll find (almost) everything we need. The most important file is ```settings.json```
At first, it'll look like [this](https://github.com/AnonymusRaccoon/Kyoo/blob/master/src/Kyoo.Host.Generic/settings.json)
We are going to take a look at the fields you might want to change to tailor Kyoo to your configuration:
- ```basics```
- ```url```: The port on which Kyoo will be exposed
For the 3 following fields, the path are relative to the directory ```settings.json``` is in
- ```pluginsPath```: The directory where the plugins are stored
- ```transmuxPath```: The directory where the transmux-ed video are stored (used as a cache)
- ```transcodePath```: The directory where the transcoded video are stored (used as a cache)
- ```database```
- ```enabled```: Which database to use. Either ```sqlite``` (by default) or ```postgres```. SQLite is easier to use & manage if you don't have an SQL server on your machine. However, if you have a large amount of videos, we recommend using Postgres, which is more powerful to manage large databases
- ```tasks```
- ```parallels```: The number of tasks that can be run at the same time. If the values is not ```1```, the behavior is not implemented.
- ```scheduled```: An object with keys being the name of an automation task, with a value being the interval between each task of the same type.
- The available keys can be found at ```/api/tasks``` (as 'slug')
- The values must be formatted like ```HH:MM:SS``
**For Example** in the default configuration, a file scan task will be executed every 24 hours
- ```media```
- ```regex```: An array of String to match files using Regex. The Regex must have the following groups:
- ```Collection```: The name of the collection. For example, you can move all the movie from a same saga in one directory, the collection's name will be the directory's. If the movie is at the root of the library, no collection will be created.
- ```Show```: the name of the show/movie
- ```StartYear``` (optional): the start year for a TV Series, or Year for a movie, used to get the correct metadata in provider
- ```Season``` (for TV Series): An integer being the number of the season
- ```Episode``` (for TV Series): An integer being the number of the episode in the season
- ```Absolute``` (optional if the two groups above are in the regex): The absolute number of the episode (from episode 1x01, ignoring seasons)
- ```subtitleRegex```: Same as ```regex```, but to find Subtitles files.
- ```Language```: A String from 1 to 3 characters long defining the language of the subtitles
- ```Default```: If present, will set the subtitle as default track
- ```Forced```: If present, will set the subtitles as forced track
- ```tvdb```
- ```apikey```: The API key that will be used to interact with the TVDB's API. See [there](https://thetvdb.com/api-information) to get one
- ```themoviedb```
- ```apikey```: The API key that will be used to interact with TMDB's API. See [there](https://developers.themoviedb.org/3/getting-started/introduction) to get one
## Using a Container
If you use Kyoo from a container, we recommend using the docker-compose file from [here](https://github.com/AnonymusRaccoon/Kyoo) and doing the following actions before launching the container:
- If you use Postgres, configure the fields ```DATABASE__CONFIGURATIONS_*```
- If you use SQLite, set the ```DATABASE__ENABLED``` to ```sqlite```
- Set the ```*APIKEY``` values
- Map the folder ```/var/lib/kyoo``` to a directory on your host, so you can access files easily, and it'll be persistent
- Map the folder ```/video``` to the media directory
- If you use Postgres, map ```/var/lib/postgresql/data``` to the host's Postgres server data folder
If you don't have a previous Kyoo configuration, we recommend using Postgres.
## Configuring Libraries
You are now ready to launch Kyoo for the first time!
But before being able to see your favorite shows & movies, we need to configure the libraries: With Kyoo, you can separate your shows into libraries, for example to split TV Series from Movies, Anime from Live-Action Series, Concerts from Documentaries.
First, you must open the server. To do so, execute the Kyoo.Host.Console binary found in the install directory.
If everything looks normal, no error message will appear, just log messages.
Then, we are going to interact with Kyoo's API. To create a library, you must do the following request for each library you want to make:
- POST Request
- At ```/api/libraries```
- Content-Type: ```application/json```
- Body:
```json
{
"name": "$KYOO_LIBRARY_NAME", // The name of the Library
"slug": "$KYOO_LIBRARY_SLUG", // The unique identifier of the Library, can be $KYOO_LIBRARY_NAME if it's unique
"paths": ["$KYOO_LIBRARY_PATH"], // Paths of directories to scan for shows in library
"providers": [
{"slug": "the-moviedb"}, // Remove if you don't want to use this provider
{"slug": "the-tvdb"} // Remove if you don't want to use this provider
]
}
```
Now that you created your libraries, you can do a simple GET request to ```/api/task/scan``` to scan for videos in all the libraries.
Once the scan is over, ```Task finished: Scan Libraries``` will be displayed! You are now ready to use Kyoo!

View File

@ -1,4 +0,0 @@
- name: Install
href: install.md
- name: Setting Up
href: setting_up.md

View File

@ -1,12 +0,0 @@
- name: Home
href: index.md
- name: Getting Started
href: start/
- name: Contributing
href: contributing/
- name: References
href: obj/api/
- name: GitHub
href: https://github.com/AnonymusRaccoon/Kyoo
- name: REST API
href: https://demo.kyoo.moe/redoc