Skip to content

Posts Stacktrace for PHP Fatal and Parse Errors to Discord embed message

License

Notifications You must be signed in to change notification settings

jehanf/apache-log-to-discord

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

apache-log-to-discord

Final result

apache-log-to-discord
The name and icon of the bot are up to you when creating a webhook (Right-click on channel > Edit channel > Integrations).

Installation

  1. git clone [email protected]:jehanf/apache-log-to-discord.git
  2. cd apache-log-to-discord
  3. npm install

Usage

node index.js /path/to/logfile.log https://discord/webhook/url

Launch in Background

Make tail.sh executable
sudo chmod +x /path/to/apache-log-to-discord/tail.sh

Then :
nohup /path/to/apache-log-to-discord/tail.sh /path/to/apache-log-to-discord/index.js "/path/to/logfile.log" "https://discord/webhook/url" > /dev/null 2>&1 &

Autostart on reboot

Make tail.sh executable
sudo chmod +x /path/to/apache-log-to-discord/tail.sh

Then :

  1. crontab -e
  2. Add @reboot /path/to/apache-log-to-discord/tail.sh /path/to/apache-log-to-discord/index.js "/path/to/logfile.log" "https://discord/webhook/url"
  3. Repeat 1 and 2 for each log you want to add

About

Posts Stacktrace for PHP Fatal and Parse Errors to Discord embed message

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 98.2%
  • Shell 1.8%