nxy irc bot
Go to file
2017-08-01 15:50:12 +02:00
bot Fixed bug in rainbow function which breaks output with numbers 2017-08-01 15:50:12 +02:00
files Updated sample configs 2017-07-31 16:12:10 +02:00
.gitignore Cleanup, fixed some bugs (yt etc) 2017-07-31 15:29:59 +02:00
FORMATTING.md Massive refactoring/-structuring 2017-07-07 02:49:37 +02:00
README.md Massive refactoring/-structuring 2017-07-07 02:49:37 +02:00
repl.py Massive refactoring/-structuring 2017-07-07 02:49:37 +02:00
requirements.txt Cleanup, fixed some bugs (yt etc) 2017-07-31 15:29:59 +02:00
TODOs Fixed bug in rainbow function which breaks output with numbers 2017-08-01 15:50:12 +02:00
tox.ini Massive refactoring/-structuring 2017-07-07 02:49:37 +02:00

Installation

  • Open shell as user nxy will run. These instructions will use nxy as user and /home/nxy as its home directory.
  • Install virtualenvwrapper (ideally system wide).
  • Open shell as user nxy, source virtualenvwrappers script
    • sudo -u nxy -i
    • source $(which virtualenvwrapper.sh)
  • Clone repo and change current dir
    • git clone https://gitfap.de/mrhanky/nxy.git
    • cd nxy
  • Create virtualenv and install dependencies
    • mkvirtualenv -a $PWD -r $PWD/requirements.txt nxy
  • Create needed tables in the database:
    • psql -U <your db user> < files/schema.sql
  • Copy files/.env and insert values in .env (replace everything wrapped in < and >)
    • cp files/.env .env
    • vim .env
  • Copy files/config.json and modify it (setup ZNC etc.)
    • cp files/config.json config.json
    • vim config.json
  • If database is empty, import your database dump:
    • psql -U nxy -d nxy < /path/to/dump.sql
  • Leave (auto) activated virtualenv and exit the bot's shell
    • deactivate && exit
  • Copy systemd unit and enable it (would recommend the /usr/local prefix). Don't forget to modify the systemd unit if your user and home directory are different!
    • sudo mkdir -p /usr/local/lib/systemd/system
    • sudo ln -fs /home/nxy/bot/files/nxy-bot.service /usr/local/lib/systemd/system
    • sudo systemctl daemon-reload
    • sudo systemctl enable --now nxy-bot.service