2020-02-17 14:58:33 +00:00
![banner ](./public/img/banner-paddings.png )
2020-02-17 14:57:02 +00:00
2020-02-25 03:19:31 +00:00
# Mango
2021-08-28 01:45:40 +00:00
[![Patreon ](https://img.shields.io/badge/support-patreon-brightgreen?link=https://www.patreon.com/hkalexling )](https://www.patreon.com/hkalexling) ![Build ](https://github.com/hkalexling/Mango/workflows/Build/badge.svg ) [![Gitter ](https://badges.gitter.im/mango-cr/mango.svg )](https://gitter.im/mango-cr/mango?utm_source=badge& utm_medium=badge& utm_campaign=pr-badge) [![Discord ](https://img.shields.io/discord/855633663425118228?label=discord )](http://discord.com/invite/ezKtacCp9Q)
2020-02-25 03:19:31 +00:00
2020-02-17 14:57:02 +00:00
Mango is a self-hosted manga server and reader. Its features include
2020-02-17 03:32:11 +00:00
- Multi-user support
2020-06-05 16:14:48 +00:00
- OPDS support
2020-03-13 17:53:54 +00:00
- Dark/light mode switch
2020-06-02 15:21:08 +00:00
- Supported formats: `.cbz` , `.zip` , `.cbr` and `.rar`
2020-03-15 17:16:19 +00:00
- Supports nested folders in library
2020-02-17 04:15:07 +00:00
- Automatically stores reading progress
2020-10-25 07:29:19 +00:00
- Thumbnail generation
2022-01-23 13:08:18 +00:00
- Supports [plugins ](https://github.com/hkalexling/mango-plugins ) to download from third-party sites
2020-02-17 03:32:11 +00:00
- The web reader is responsive and works well on mobile, so there is no need for a mobile app
- All the static files are embedded in the binary, so the deployment process is easy and painless
2020-02-11 22:06:17 +00:00
2020-06-09 15:12:23 +00:00
Please check the [Wiki ](https://github.com/hkalexling/Mango/wiki ) for more information.
2020-02-11 22:06:17 +00:00
## Installation
2020-02-22 02:21:34 +00:00
### Pre-built Binary
2020-04-06 14:44:45 +00:00
Simply download the pre-built binary file `mango` for the latest [release ](https://github.com/hkalexling/Mango/releases ). All the dependencies are statically linked, and it should work with most Linux systems on amd64.
2020-02-22 02:21:34 +00:00
2020-02-17 16:46:15 +00:00
### Docker
2020-02-17 22:28:09 +00:00
1. Make sure you have docker installed and running. You will also need `docker-compose`
2020-02-17 17:36:11 +00:00
2. Clone the repository
2020-04-06 19:43:12 +00:00
3. Copy the `env.example` file to `.env`
4. Fill out the values in the `.env` file. Note that the main and config directories will be created if they don't already exist. The files in these folders will be owned by the root user
2020-02-20 04:23:11 +00:00
5. Run `docker-compose up` . This should build the docker image and start the container with Mango running inside
2020-04-06 19:43:12 +00:00
6. Head over to `localhost:9000` (or a different port if you changed it) to log in
2020-02-17 22:28:09 +00:00
2020-04-06 14:44:45 +00:00
### Docker (via Dockerhub)
2020-05-24 06:47:19 +00:00
The official docker images are available on [Dockerhub ](https://hub.docker.com/r/hkalexling/mango ).
2020-04-06 14:44:45 +00:00
2020-02-17 03:32:11 +00:00
### Build from source
2020-06-02 15:26:38 +00:00
1. Make sure you have `crystal` , `shards` and `yarn` installed. You might also need to install the development headers of some libraries. Please see the [Dockerfile ](https://github.com/hkalexling/Mango/blob/master/Dockerfile ) for the full list of dependencies
2020-02-17 03:32:11 +00:00
2. Clone the repository
2020-02-17 16:46:15 +00:00
3. `make && sudo make install`
2020-02-19 02:57:06 +00:00
4. Start Mango by running the command `mango`
5. Head over to `localhost:9000` to log in
2020-02-11 22:06:17 +00:00
## Usage
2020-02-17 03:32:11 +00:00
### CLI
```
2022-03-28 14:14:17 +00:00
Mango - Manga Server and Web Reader. Version 0.26.0
2020-02-17 03:32:11 +00:00
2020-06-02 15:26:38 +00:00
Usage:
mango [sub_command] [options]
Options:
-c PATH, --config=PATH Path to the config file [type:String]
-h, --help Show this help.
-v, --version Show version.
Sub Commands:
admin Run admin tools
2020-02-17 03:32:11 +00:00
```
### Config
2020-02-20 04:23:11 +00:00
The default config file location is `~/.config/mango/config.yml` . It might be different if you are running Mango in a docker container. The config options and default values are given below
2020-02-11 22:06:17 +00:00
2020-02-17 03:32:11 +00:00
```yaml
---
2021-03-04 04:48:51 +00:00
host: 0.0.0.0
2020-02-17 03:32:11 +00:00
port: 9000
2020-05-24 06:33:05 +00:00
base_url: /
2020-10-18 12:50:51 +00:00
session_secret: mango-session-secret
2020-06-02 15:56:39 +00:00
library_path: ~/mango/library
2020-05-24 06:33:05 +00:00
db_path: ~/mango/mango.db
2022-02-06 06:28:10 +00:00
queue_db_path: ~/mango/queue.db
2020-02-17 03:32:11 +00:00
scan_interval_minutes: 5
2020-10-25 07:29:19 +00:00
thumbnail_generation_interval_hours: 24
2020-02-17 03:32:11 +00:00
log_level: info
2020-05-24 06:33:05 +00:00
upload_path: ~/mango/uploads
2020-10-18 12:50:51 +00:00
plugin_path: ~/mango/plugins
download_timeout_seconds: 30
2021-09-20 01:36:31 +00:00
library_cache_path: ~/mango/library.yml.gz
cache_enabled: false
cache_size_mbs: 50
cache_log_enabled: true
2021-01-09 06:35:11 +00:00
disable_login: false
default_username: ""
2021-03-04 04:48:51 +00:00
auth_proxy_header_name: ""
2022-03-28 14:17:54 +00:00
plugin_update_interval_hours: 24
2020-02-17 03:32:11 +00:00
```
2020-02-11 22:06:17 +00:00
2022-03-28 14:17:54 +00:00
- `scan_interval_minutes` , `thumbnail_generation_interval_hours` , and `plugin_update_interval_hours` can be any non-negative integer. Setting them to `0` disables the periodic tasks
2020-02-17 16:46:15 +00:00
- `log_level` can be `debug` , `info` , `warn` , `error` , `fatal` or `off` . Setting it to `off` disables the logging
2021-01-09 06:35:11 +00:00
- You can disable authentication by setting `disable_login` to true. Note that `default_username` must be set to an existing username for this to work.
2021-09-20 01:36:31 +00:00
- By setting `cache_enabled` to `true` , you can enable an experimental feature where Mango caches library metadata to improve page load time. You can further fine-tune the feature with `cache_size_mbs` and `cache_log_enabled` .
2020-02-17 16:46:15 +00:00
2020-03-17 15:45:46 +00:00
### Library Structure
2020-06-02 15:21:08 +00:00
You can organize your archive files in nested folders in the library directory. Here's an example:
2020-03-17 15:45:46 +00:00
```
.
├── Manga 1
│ ├── Volume 1.cbz
│ ├── Volume 2.cbz
│ ├── Volume 3.cbz
2020-03-17 15:59:32 +00:00
│ └── Volume 4.zip
2020-03-17 15:45:46 +00:00
└── Manga 2
└── Vol. 1
└── Ch.1 - Ch.3
2020-05-24 06:47:19 +00:00
├── 1.zip
├── 2.zip
2020-03-17 15:45:46 +00:00
└── 3.zip
```
2020-02-17 04:15:07 +00:00
### Initial Login
2020-02-11 22:06:17 +00:00
2020-02-17 04:15:07 +00:00
On the first run, Mango would log the default username and a randomly generated password to STDOUT. You are advised to immediately change the password.
2020-02-11 22:06:17 +00:00
2020-02-17 04:15:07 +00:00
## Screenshots
2020-02-11 22:06:17 +00:00
2020-02-17 17:36:11 +00:00
Library:
2020-02-17 16:46:15 +00:00
![library screenshot ](./.github/screenshots/library.png )
2020-02-17 17:36:11 +00:00
Title:
2020-02-17 16:46:15 +00:00
![title screenshot ](./.github/screenshots/title.png )
2020-03-13 18:00:22 +00:00
Dark mode:
![dark mode screeshot ](./.github/screenshots/dark.png )
2020-02-17 17:36:11 +00:00
Reader:
2020-02-17 16:46:15 +00:00
![reader screenshot ](./.github/screenshots/reader.png )
2020-02-17 17:36:11 +00:00
Mobile UI:
2020-02-17 16:46:15 +00:00
![mobile screenshot ](./.github/screenshots/mobile.png )
2020-03-01 02:47:59 +00:00
2020-08-06 04:49:43 +00:00
## Sponsors
< a href = "https://casinoshunter.com/online-casinos/" > < img src = "https://i.imgur.com/EJb3wBo.png" width = "150" height = "auto" > < / a >
2020-09-22 08:54:20 +00:00
< a href = "https://www.browserstack.com/open-source" > < img src = "https://i.imgur.com/hGJUJXD.png" width = "150" height = "auto" > < / a >
2020-08-06 04:49:43 +00:00
2020-03-01 02:47:59 +00:00
## Contributors
2020-08-08 09:04:42 +00:00
Please check the [development guideline ](https://github.com/hkalexling/Mango/wiki/Development ) if you are interested in code contributions.
2021-01-11 11:25:42 +00:00
<!-- ALL - CONTRIBUTORS - LIST:START - Do not remove or modify this section -->
<!-- prettier - ignore - start -->
<!-- markdownlint - disable -->
< table >
< tr >
< td align = "center" > < a href = "https://github.com/hkalexling/" > < img src = "https://avatars1.githubusercontent.com/u/7845831?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > Alex Ling< / b > < / sub > < / a > < br / > < a href = "https://github.com/hkalexling/Mango/commits?author=hkalexling" title = "Code" > 💻< / a > < a href = "https://github.com/hkalexling/Mango/commits?author=hkalexling" title = "Documentation" > 📖< / a > < a href = "#infra-hkalexling" title = "Infrastructure (Hosting, Build-Tools, etc)" > 🚇< / a > < / td >
< td align = "center" > < a href = "https://github.com/jaredlt" > < img src = "https://avatars1.githubusercontent.com/u/8590311?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > jaredlt< / b > < / sub > < / a > < br / > < a href = "https://github.com/hkalexling/Mango/commits?author=jaredlt" title = "Code" > 💻< / a > < a href = "#ideas-jaredlt" title = "Ideas, Planning, & Feedback" > 🤔< / a > < a href = "#design-jaredlt" title = "Design" > 🎨< / a > < / td >
< td align = "center" > < a href = "https://windisco.com/" > < img src = "https://avatars1.githubusercontent.com/u/4946624?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > ココロ< / b > < / sub > < / a > < br / > < a href = "#infra-shincurry" title = "Infrastructure (Hosting, Build-Tools, etc)" > 🚇< / a > < / td >
< td align = "center" > < a href = "https://catgirlsin.space/" > < img src = "https://avatars0.githubusercontent.com/u/13433513?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > Valentijn< / b > < / sub > < / a > < br / > < a href = "#infra-noirscape" title = "Infrastructure (Hosting, Build-Tools, etc)" > 🚇< / a > < / td >
< td align = "center" > < a href = "https://github.com/flying-sausages" > < img src = "https://avatars1.githubusercontent.com/u/23618693?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > flying-sausages< / b > < / sub > < / a > < br / > < a href = "https://github.com/hkalexling/Mango/commits?author=flying-sausages" title = "Documentation" > 📖< / a > < a href = "#ideas-flying-sausages" title = "Ideas, Planning, & Feedback" > 🤔< / a > < / td >
< td align = "center" > < a href = "https://github.com/XavierSchiller" > < img src = "https://avatars1.githubusercontent.com/u/22575255?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > Xavier< / b > < / sub > < / a > < br / > < a href = "#infra-XavierSchiller" title = "Infrastructure (Hosting, Build-Tools, etc)" > 🚇< / a > < / td >
< td align = "center" > < a href = "https://github.com/WROIATE" > < img src = "https://avatars3.githubusercontent.com/u/44677306?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > Jarao< / b > < / sub > < / a > < br / > < a href = "#infra-WROIATE" title = "Infrastructure (Hosting, Build-Tools, etc)" > 🚇< / a > < / td >
< / tr >
< tr >
< td align = "center" > < a href = "https://github.com/Leeingnyo" > < img src = "https://avatars0.githubusercontent.com/u/6760150?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > 이인용< / b > < / sub > < / a > < br / > < a href = "https://github.com/hkalexling/Mango/commits?author=Leeingnyo" title = "Code" > 💻< / a > < / td >
2021-01-11 11:31:20 +00:00
< td align = "center" > < a href = "http://h45h74x.eu.org" > < img src = "https://avatars1.githubusercontent.com/u/27204033?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > Simon< / b > < / sub > < / a > < br / > < a href = "https://github.com/hkalexling/Mango/commits?author=h45h74x" title = "Code" > 💻< / a > < / td >
2021-02-14 15:28:32 +00:00
< td align = "center" > < a href = "https://github.com/davidkna" > < img src = "https://avatars.githubusercontent.com/u/835177?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > David Knaack< / b > < / sub > < / a > < br / > < a href = "#infra-davidkna" title = "Infrastructure (Hosting, Build-Tools, etc)" > 🚇< / a > < / td >
2021-09-08 12:42:09 +00:00
< td align = "center" > < a href = "https://lncn.dev" > < img src = "https://avatars.githubusercontent.com/u/41193328?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > i use arch btw< / b > < / sub > < / a > < br / > < a href = "#infra-lincolnthedev" title = "Infrastructure (Hosting, Build-Tools, etc)" > 🚇< / a > < / td >
2022-01-25 05:14:08 +00:00
< td align = "center" > < a href = "https://github.com/BradleyDS2" > < img src = "https://avatars.githubusercontent.com/u/2174921?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > BradleyDS2< / b > < / sub > < / a > < br / > < a href = "https://github.com/hkalexling/Mango/commits?author=BradleyDS2" title = "Documentation" > 📖< / a > < / td >
2022-01-26 11:52:11 +00:00
< td align = "center" > < a href = "https://github.com/nduja" > < img src = "https://avatars.githubusercontent.com/u/69299134?v=4?s=100" width = "100px;" alt = "" / > < br / > < sub > < b > Robbo< / b > < / sub > < / a > < br / > < a href = "https://github.com/hkalexling/Mango/commits?author=nduja" title = "Code" > 💻< / a > < / td >
2021-01-11 11:25:42 +00:00
< / tr >
< / table >
<!-- markdownlint - restore -->
<!-- prettier - ignore - end -->
<!-- ALL - CONTRIBUTORS - LIST:END -->