Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pavsap/homebrew-clickhouse
Homebrew Service for ClickHouse
https://github.com/pavsap/homebrew-clickhouse
clickhouse clickhouse-server homebrew homebrew-formulae homebrew-services
Last synced: 3 days ago
JSON representation
Homebrew Service for ClickHouse
- Host: GitHub
- URL: https://github.com/pavsap/homebrew-clickhouse
- Owner: pavsap
- License: other
- Created: 2025-01-14T17:46:33.000Z (10 days ago)
- Default Branch: main
- Last Pushed: 2025-01-14T17:48:56.000Z (10 days ago)
- Last Synced: 2025-01-19T14:44:05.294Z (5 days ago)
- Topics: clickhouse, clickhouse-server, homebrew, homebrew-formulae, homebrew-services
- Language: Ruby
- Homepage:
- Size: 4.88 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ClickHouse Homebrew Tap
Run [ClickHouse](https://formulae.brew.sh/cask/clickhouse) database as a
service on macOS with standard [Homebrew](https://brew.sh) commands:## Installation
1. Install clickhouse:
```bash
brew install --cask clickhouse
```2. Install clickhouse service wrapper:
```bash
# Add this tap
brew tap pavsap/clickhouse# Install server wrapper
brew install clickhouse-server
```## Usage
### Service Management
```bash
# Basic service control
brew services start|stop|restart clickhouse-server# Check service status
brew services info clickhouse-server# Manual start (without service)
clickhouse server --config-file=/opt/homebrew/etc/clickhouse-server/config.xml
```### Test Installation
```bash
# Test local queries
clickhouse client -q 'SELECT 1'
clickhouse client -q 'SELECT version()'# Test connectivity
curl 'http://localhost:8123/ping'
curl 'http://localhost:8123/?query=SELECT%201'
```### Configuration
Default configuration files are located at:
- `/opt/homebrew/etc/clickhouse-server/config.xml`
- `/opt/homebrew/etc/clickhouse-server/users.xml`Data directory:
- `/opt/homebrew/var/lib/clickhouse`Log files:
- `/opt/homebrew/var/log/clickhouse-server/clickhouse-server.log`
- `/opt/homebrew/var/log/clickhouse-server/clickhouse-server.err.log`## Security
Default configuration:
- Empty password for default user
- Access restricted to localhost (127.0.0.1 and ::1)
- Default ports:
- HTTP: 8123
- Native: 9000
- Interserver: 9009⚠️ Consider changing default passwords in production environments.
## Upgrading
Configuration files are not overwritten on upgrade. To use new configurations:
1. Backup existing files
2. Remove them
3. Reinstall the formula## Troubleshooting
### Common Issues
1. Binary not found:
```bash
brew reinstall --cask clickhouse
brew reinstall clickhouse-server
```2. Permission issues:
```bash
sudo chown -R $(whoami) /opt/homebrew/var/lib/clickhouse
sudo chown -R $(whoami) /opt/homebrew/var/log/clickhouse-server
```3. Port conflicts:
Edit ports in config.xml and restart the service.## Contributing
1. Fork the repository
2. Create your feature branch
3. Commit your changes
4. Push to the branch
5. Create a Pull Request## License
This project is licensed under the Apache License 2.0 - see the
[LICENSE](LICENSE) file for details.## Acknowledgments
- [Homebrew](https://brew.sh/)
- [ClickHouse](https://clickhouse.com/)