Advertisement
Justman10000

Manage Chatwoot

Aug 6th, 2023 (edited)
899
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.89 KB | None | 0 0
  1. // To install
  2. # You need Ruby and Rails (https://pastebin.com/BR9eYkwv)
  3.  
  4. mkdir /home/Chatwoot
  5. cd /home/Chatwoot
  6.  
  7. git init
  8. git remote add origin https://github.com/chatwoot/chatwoot.git
  9. git pull origin develop
  10. git branch -m develop
  11.  
  12. rm -r .* *.md LICENSE *.lock
  13. wget https://github.com/chatwoot/chatwoot/raw/develop/.env.example -O .env
  14.  
  15. bundle install
  16.  
  17. RAILS_ENV=production rake db:setup
  18. RAILS_ENV=production rake db:migrate
  19. RAILS_ENV=production rake db:seed
  20.  
  21. yarn
  22. RAILS_ENV=production rails assets:precompile
  23.  
  24. # For debugging
  25. rails server -e production -b 0.0.0.0 -p 4679
  26. # For background use
  27. rails server -e production -d -b 0.0.0.0 -p 4679
  28.  
  29. // To uninstall
  30. lsof -i:4679 # Under COMMAND it says ruby, copy the PID one column to the right
  31. kill #id
  32. rm -r /home/Chatwoot
  33. psql << EOF
  34. DROP DATABASE chatwoot_test;
  35. DROP DATABASE chatwoot_dev;
  36. DROP DATABASE chatwoot_production;
  37. EOF
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement