A manager (backend) for ss-libev. Aims to manage user accounts and traffics based on database.
- Install python3.5+
- Install requirements using the following commands
cd ssman-libev pip install -r requirement.txt
- Setup database. Execute following commands in mysql
then in bash execute
create database ssman; grant all privileges on ssman.* to 'yourdbusername'@'%' identified by 'yourpassword'; quit
cd ssman-libev mysql -uyourdbusername -pyourpassword ssman < ssman.sql
-
Prepare your data in database
-
Set up your configurations in
config.py
-
Add
_cron_user_manager.py
and_cron_reminder_mail.py
(optional) to your crontab on Database Server_cron_user_manager.py
should run every a few minutes, but_cron_reminder_mail.py
should only run once per day, or the users may get several reminder mails in one day. -
Start ss-libev(ss-manager mode) program on ss server. You can run it from docker using:
docker run -itd --net=host --restart=always --name=ss-libev dylanchu/ss-libev ss-manager -u -m aes-128-cfb -u --manager-address 127.0.0.1:6001 -s :: -s 0.0.0.0
-
Run
client_server.py
on ss server
_cron_user_manager.py is necessary and should be executed every a few minutes;
_cron_reminder_mail.py is optional and can be executed once a day;
_cron_reset_traffic.py is necessary and should be executed at the first day of every month.