A custom MangaCMS built on NET.ASP MVC and Razor pages.
- Uploading actual image files as chapter pages does NOT work.
Please don't make any issues about that.
I plan to add it in the somewhat near future.
- Profile image uploads still work as well as all other image uploads.
This project uses environment variables for secure configuration. This is the recommended way to handle database credentials and other sensitive information without hardcoding them in the source code.
The following environment variables are used in Program.cs to build the MySQL connection string:
| Variable | Description | Default Value (if not set) |
|---|---|---|
MYSQL_HOST |
The IP address or hostname of your MySQL server | YOUR_DATABASE_HOST_IP |
MYSQL_PORT |
The port your MySQL server is listening on | 3306 |
MYSQL_DB |
The name of the database for the reader | YOUR_DATABASE_NAME |
MYSQL_USER |
The database user with read/write permissions | YOUR_DATABASE_USER |
MYSQL_PASSWORD |
The password for the database user | YOUR_DATABASE_PASSWORD |
For local development, you can set these in your terminal or via your IDE (like Rider or Visual Studio) in the "Run/Debug Configurations" menu.
PowerShell:
$env:MYSQL_HOST="127.0.0.1"
$env:MYSQL_DB="manga_db"
$env:MYSQL_USER="root"
$env:MYSQL_PASSWORD="your_password"Bash:
export MYSQL_HOST="127.0.0.1"
export MYSQL_DB="manga_db"
export MYSQL_USER="root"
export MYSQL_PASSWORD="your_password"If running via Docker, add them to your docker-compose.yml or docker run command:
environment:
- MYSQL_HOST=db_host
- MYSQL_DB=manga_db
- MYSQL_USER=admin
- MYSQL_PASSWORD=secret_passNever commit your actual .env files or hardcode real passwords back into Program.cs. Always keep these values private to your server environment.
Note: This is not neccessary but it is recommended as sometimes I'll probably forget to compile it myself and you'll be using an older version.
To get started run:
dotnet publish -c Release -r linux-x64 --self-contained true -o .\publish
This will generate the following folders:
- bin
- publish
- wwwroot
Using any software that allows file transfers using FTP
- Move the contents of
MangaReader/bin/Release/net10.0/linux-x64/folder into the root folder of your projec on your VPS. - Move both folders
wwwrootandpublishin the same folder. - Set the run command to
dotnet MangaReader.dll --urls "http://$IP:$PORT"