macOS Development Setup
This guide will help you set up your macOS development environment for contributing to Chatwoot. Open Terminal app and run the following commands.Installing the Standalone Command Line Tools
Open Terminal app and run:Install Homebrew
Homebrew is the missing package manager for macOS:Install Git
Install Ruby Version Manager
Choose between RVM or rbenv for managing Ruby versions.Option 1: Install RVM (Recommended)
Option 2: Install rbenv (Alternative)
Install Ruby
Chatwoot APIs are built on Ruby on Rails. You need to install Ruby 3.2.2.If using RVM:
If using rbenv:
rbenv identifies the ruby version from
.ruby-version
file on the root of the project and loads it automatically.Install Node.js
Chatwoot requires Node.js version 20:Install pnpm
We usepnpm
as our package manager for better performance:
Install PostgreSQL
The database used in Chatwoot is PostgreSQL.Option 1: PostgresApp (Recommended)
- Download and install PostgresApp from https://postgresapp.com
- This is the easiest way to get started with PostgreSQL on macOS
- Follow the setup instructions on their website
Option 2: Homebrew Installation
Install Redis Server
Chatwoot uses Redis server for agent assignments and reporting:Install ImageMagick
Chatwoot uses ImageMagick library to resize images for previews and thumbnails:Install Additional Dependencies
Install other useful development tools:Install Docker (Optional)
For development and testing with containers:Environment Verification
Verify all installations are working:Configure Shell Environment
Add useful aliases to your shell configuration file (~/.zshrc
for Zsh):
Troubleshooting Common Issues
Command line tools installation fails
Command line tools installation fails
Solution: Update macOS to the latest version and try again. You can also download Xcode from the App Store.
Homebrew installation permission errors
Homebrew installation permission errors
Solution:
Ruby installation fails with RVM
Ruby installation fails with RVM
Solution:
PostgreSQL connection refused
PostgreSQL connection refused
Solution:
ImageMagick installation issues
ImageMagick installation issues
Solution:
Getting Help
If you encounter issues:- Common Errors: Check Common Errors
- Discord Community: Join our Discord
- GitHub Issues: Create an issue
Your macOS development environment is now ready for Chatwoot development! 🚀