Thanks to visit codestin.com
Credit goes to github.com

Skip to content

erfjab/LiteGuard

Repository files navigation

Important

We thank MagicMizban for supporting and sponsoring this project.

Setup

Server and Docker Setup

Show Server Commands

1. Update the Server

sudo apt update && sudo apt upgrade -y

2. Install Docker

curl -fsSL https://get.docker.com | sh

Install & Run the Bot

Show Run Commands

1. Create Directory and Download Files

mkdir -p /opt/erfjab/liteguard/data
curl -o /opt/erfjab/liteguard/docker-compose.yml https://raw.githubusercontent.com/erfjab/liteguard/master/docker-compose.yml
cd /opt/erfjab/liteguard
curl -o .env https://raw.githubusercontent.com/erfjab/liteguard/master/.env.example

2. SSL Configuration

Before configuring the environment, you need to set up SSL certificates for your domain. The SSL files must be placed in the /opt/erfjab/liteguard/data directory.

For obtaining SSL certificates, you can use the ESSL repository which provides automated SSL certificate generation.

Important: Make sure port 443 is open and available on your server, as the project requires it. If port 443 is occupied by another service (like Nginx or HAProxy), you'll need to configure those services to work alongside LiteGuard or use a different configuration.

3. Config .env

nano .env

4. Pull Docker Image

docker compose pull

5. Start the Bot

docker compose up -d

After a few moments, the bot will start running.


Update the Bot

Show Update Commands

Make sure you're in the liteguard directory:

cd /opt/erfjab/liteguard

Then update the bot:

docker compose pull && docker compose up -d

Manage the Bot

Show Manage Commands

Make sure you're in the liteguard directory:

cd /opt/erfjab/liteguard
  • Restart the Bot:

    docker compose restart
  • Stop the Bot:

    docker compose down
  • View Logs:

    docker compose logs -f

Switch to GA Mode (preview mode)

Show GA Commands

Make sure you're in the HolderBot directory:

cd /opt/erfjab/liteguard
  • Open the Docker Compose File:

    nano docker-compose.yml
  • Change the Image Tag:

    From:

    erfjab/liteguard:latest

    To:

    erfjab/liteguard:ga
  • Pull the Docker Image:

    docker compose pull
  • Start the Bot:

    docker compose up -d

Support

Star the Project:
Stargazers