Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/gxrwes/wetflix

Wetflix: A web application for streaming movies and TV shows directly from your NAS. Features include user management, role-based access, viewing history, playlists, favorites, and metadata scraping, all easily deployable via Docker.
https://github.com/gxrwes/wetflix

blazor movies-streaming nas netflix-clone tv-shows video-streaming

Last synced: 2 months ago
JSON representation

Wetflix: A web application for streaming movies and TV shows directly from your NAS. Features include user management, role-based access, viewing history, playlists, favorites, and metadata scraping, all easily deployable via Docker.

Awesome Lists containing this project

README

        

# Wetflix

**Wetflix** is a web application designed for viewing movies and TV shows stored on a NAS (Network-Attached Storage). The application mounts and scans the NAS for content, builds a database of your media collection, and provides a user-friendly interface for browsing and viewing. Wetflix includes comprehensive user management and authorization features, supports metadata scraping from popular movie databases, and is built to run in a Docker container.

## Features

- **NAS Integration**: Automatically mounts and scans your NAS for available content.
- **Database Management**: Builds and maintains a database of your movies and TV shows.
- **User Management and Authorization**: Supports multiple users with role-based access and management, including:
- Account request and approval system for new users.
- Admins can manage users, roles, and permissions.
- Users can be assigned to specific roles (Admin, Moderator, User, Guest).
- **Viewing History**: Tracks and displays the last 10 watched items for users. Admins can view a complete watch history for all users.
- **Playlists**: Users can create and manage playlists of movies and TV shows.
- Playlists are displayed on the home page with a visual representation of the contained items.
- Playlists can be clicked to view their full content, including linked movies and TV shows.
- **Favorites**: Users can add movies and TV shows to their favorites for quick access.
- **Supported File Types**: Currently supports `.mp4` files, with more file types planned in future updates.
- **Metadata Scraping**: Retrieves metadata and cover art for movies from TMDB, OMDB, and IMDB.
- **Local Network Optimization**: Downloads and caches cover art locally for improved performance on local networks.
- **Dockerized Application**: Easily deployable as a Docker container.
- **Email Notification support**: Send email, currently implemented for user creation.

## Latest Updates
- **Email Sending** - can now send emails
- **Thread Saftey** - issues with threadsaftey occured when some services where called multiple times in a single page. This fixed
- *WatchHistory not showing*
- *Playlists and Favorites not showing*
- *User Account Request and Creation failing at Db access*
- **Ui Facelift** - minor ui changes to make some stuff look nicer

## Getting Started

### Prerequisites

Before you start, ensure you have the following:

- **NAS Server**: Accessible from the Docker host.
- **Docker**: Installed on your machine.
- **.env File**: Create a `.env` file with the following environment variables:

```
NAS_SERVER=
NAS_SHARENAME=
NAS_USERNAME=
NAS_PASSWORD=

# Docker-specific database settings
DB_SERVER=db
DB_DATABASE=Wetflix
DB_USERNAME=sa
DB_PASSWORD=YourStrong@Passw0rd
DB_CONNECTION_STRING="Server=${DB_SERVER};Database=${DB_DATABASE};User Id=${DB_USERNAME};Password=${DB_PASSWORD};TrustServerCertificate=True;"

# API Keys
OMDB_API_KEY=
TMDB_API_KEY=

# ASP.NET Core Environment
ASPNETCORE_ENVIRONMENT=Production

# Admin Account Defaults
ADMIN_USER_DEFAULT_PW=
ADMIN_USER_EMAIL=

# If you wish to use SSL
SSL_CERTIFICATE_PATH=
SSL_CERTIFICATE_PASSWORD=
ENABLE_HTTPS=
HOST_EMAIL_PW=
HOST_EMAIL=

```

Replace the placeholder values with your actual configuration.

### Docker Compose Configuration

Wetflix is designed to run with Docker Compose. Below are two example configurations: one for the development build and one for the latest stable build.

#### Development Build Configuration

```yaml
version: '3.8'

services:
web:
image: gxrwes/wetflix:dev
build:
context: ../Wetflix/Wetflix.App # Adjust this path according to your structure
dockerfile: ./Wetflix.App/Dockerfile # Dockerfile relative to the context
ports:
- "8443:443" # Map an alternative port for HTTPS
- "8080:8080" # Map port 8080 on the host to port 8080 in the container
env_file:
- .env # Using the .env file for environment variables
environment:
- ASPNETCORE_ENVIRONMENT=Development
- DB_CONNECTION_STRING=${DB_CONNECTION_STRING} # Using the connection string from the .env file
privileged: true # Allows full access to host capabilities (needed for mounting)
depends_on:
- db
volumes:
- /mnt:/mnt # Mount the /mnt directory so that the container can mount drives here
- ./ssl-certs:/ssl-certs:ro # Mount the certificate directory as read-only

db:
image: mcr.microsoft.com/mssql/server:2022-latest
environment:
SA_PASSWORD: "${DB_PASSWORD}"
ACCEPT_EULA: "Y"
MSSQL_PID: "Express"
ports:
- "1433:1433"
volumes:
- sql_data:/var/opt/mssql

volumes:
sql_data:

```

#### Stable Build Configuration

```yaml
version: '3.8'

services:
web:
image: gxrwes/wetflix:latest
build:
context: ../Wetflix/Wetflix.App # Adjust this path according to your structure
dockerfile: ./Wetflix.App/Dockerfile # Dockerfile relative to the context
ports:
- "8443:443" # Map an alternative port for HTTPS
- "8080:8080" # Map port 8080 on the host to port 8080 in the container
env_file:
- .env # Using the .env file for environment variables
environment:
- ASPNETCORE_ENVIRONMENT=Production
- DB_CONNECTION_STRING=${DB_CONNECTION_STRING} # Using the connection string from the .env file
privileged: true # Allows full access to host capabilities (needed for mounting)
depends_on:
- db
volumes:
- /mnt:/mnt # Mount the /mnt directory so that the container can mount drives here
- ./ssl-certs:/ssl-certs:ro # Mount the certificate directory as read-only

db:
image: mcr.microsoft.com/mssql/server:2022-latest
environment:
SA_PASSWORD: "${DB_PASSWORD}"
ACCEPT_EULA: "Y"
MSSQL_PID: "Express"
ports:
- "1433:1433"
volumes:
- sql_data:/var/opt/mssql

volumes:
sql_data:
```

### Running the Application

1. **Clone the Repository**:
Clone the Wetflix repository to your local machine.

2. **Set Up the .env File**:
Create a `.env` file in the root directory of the project and populate it with the environment variables described above.

3. **Run Docker Compose**:
Navigate to the directory containing your `docker-compose.yml` file and run the following command:

```bash
docker-compose up -d
```

4. **Access the Application**:
Once the services are up and running, you can access the Wetflix application by navigating to `http://localhost:8080` in your web browser.

### Future Plans

- **Support for Audio**: Adding support for audiobooks and music.
- **Additional File Type Support**: Expanding support to more video file formats beyond `.mp4`.
- **Enhanced User Interface**: Improved user experience with additional features and customizations.

## Known Limitations

- **HTTPS Support**: can be enabled via a Env Variable ( look above ), requires a cert to be generated and properly mounted in docker-compose
- **Limited File Format Support**: Only `.mp4` is fully supported. More formats will be added in future releases.

## Contributing

Contributions are welcome! Please submit a pull request or open an issue to discuss potential changes or features.

## License

Wetflix is licensed under the MIT License. See the LICENSE file for more details.

---