Posted by admin February 22nd 2019 at 16:02

yum clean all

yum update

vi /etc/yum.repos.d/mongodb-org-4.0.repo

[mongodb-org-4.0]
name=MongoDB Repository
baseurl=https://repo.mongodb.org/yum/redhat/$releasever/mongodb-org/4.0/x86_64/
gpgcheck=1
enabled=1
gpgkey=https://www.mongodb.org/static/pgp/server-4.0.asc
yum update
yum install mongodb-org-server mongodb-org mongodb-org-mongos mongodb-org-shell mongodb-org-tools
systemctl enable mongod
systemctl start mongod
install -g inherits n
yum install GraphicsMagick
cd /opt
curl -L https://releases.rocket.chat/latest/download -o rocket.chat.tar
tar -xvf rocket.chat.tar
mkdir -p /var/www/html/rocket.chat
cd bundle
mv * .[^.]* /var/www/html/rocket.chat/
cd /var/www/html/rocket.chat/programs/server

npm install
yum install -y gcc-c++ make
cd ../../
export ROOT_URL=http://your-server_IP:3000/
export MONGO_URL=mongodb://localhost:27017/rocketchat
export PORT=3000

node main.js