#! /bin/sh -e

setsebool -P httpd_can_network_connect 1

service nginx status > /dev/null && service nginx reload || service nginx start
service mongod status > /dev/null || service mongod start
service elasticsearch status > /dev/null || service elasticsearch start
service rabbitmq-server status > /dev/null || service rabbitmq-server start
service redis status > /dev/null || service redis start

systemctl daemon-reload
systemctl enable openpaas
systemctl start openpaas
