Easily run Rocket.Chat on FreeBSD.
The installation script is currently configured to install Rocket.Chat 0.73.2. The installation script has only been tested on FreeBSD 12.0 with node 8.15.0 and npm 6.6.0.
To begin the installation, run the following as a superuser:
fetch https://raw.githubusercontent.com/rdnn/Rocket.Chat-freebsd/master/rocketchat
chmod +x rocketchat
./rocketchat
Once complete, start the MongoDB and Rocket.Chat services:
service mongod start
service rocketchat start
The startup process can then be monitored:
tail -f /var/log/rocketchat/forever.log
If all goes well, you should see the following:
➔ +----------------------------------------------+
➔ | SERVER RUNNING |
➔ +----------------------------------------------+
➔ | |
➔ | Rocket.Chat Version: 0.73.2 |
➔ | NodeJS Version: 8.15.0 - x64 |
➔ | Platform: freebsd |
➔ | Process Port: 3000 |
➔ | Site URL: http://localhost:3000 |
➔ | ReplicaSet OpLog: Disabled |
➔ | Commit Hash: 8ff0e3da16 |
➔ | Commit Branch: HEAD |
➔ | |
➔ +----------------------------------------------+
The installation script is a simple shell script that fetches the official Rocket.Chat Docker deployment image and then extracts, modifies, builds, and installs Rocket.Chat. The installation script has rudimentary error checking and will not catch all errors. For that reason, among others, it is recommended that the installation script be used within a jail. Once executed, the installation script will...
- Use
pkg
to install the packages required to build and run Rocket.Chat:- jq
- mongodb36
- node8
- npm-node8
- pkgconf
- python
- python2
- python27
- vips
- Create a user and group named
rocketchat
- Create the required directories:
/var/run/rocketchat
/var/log/rocketchat
/usr/local/rocketchat
- Download the Rocket.Chat Docker deployment image directly from https://releases.rocket.chat
- Extract, apply FreeBSD-specific modifications, build, and install Rocket.Chat in
/usr/local/rocketchat
- Configure newsyslog for log management and rotation
- Install forever globally to ensure Rocket.Chat runs continuously
- Install a rc.d script in
/usr/local/etc/rc.d
to allow the service command to manage Rocket.Chat - Add the MongoDB and Rocket.Chat services to
/etc/rc.conf