How to Install Cerb Collaboration and Email Automation on CentOS 7

前端之家收集整理的这篇文章主要介绍了How to Install Cerb Collaboration and Email Automation on CentOS 7前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

Cerb is a free and open source web-based application software for collaboration and email automation. It is written in PHP language and uses MysqL/MariaDB as a database. It is used for sending a large number of emails.

Here,we will explain how to install Cerb on CentOS 7 server.

Requirements

  • A CentOS 7 server installed on your system.

  • A sudo user with root privileges.

1 Getting Started

Let's start by installing EPEL repo and updating the system with the latest stable version.

You can do this by running the following command:

sudo yum install epel-release -y
sudo yum update -y

2 Install LAMP Server

Before starting,you will need to install LAMP server (Apache,MariaDB and PHP) in your system.

First,install Apache and MariaDB with the following command:

sudo yum install httpd mariadb mariadb-server -y

Once the installation is complete,start the Apache and MariaDB service and enable them to start on boot:

sudo systemctl start httpd
sudo systemctl enable httpd
sudo systemctl start mariadb
sudo systemctl enable mariadb

Next,install PHP and other required modules with the following command:

sudo yum install install PHP PHP-curl PHP-dom PHP-gd PHP-MysqLi PHP-openssl PHP-pcre PHP-imap PHP-json PHP-mbstring PHP-session PHP-simplexml PHP-xml PHP-spl PHP-mailparse -y

PHP.ini file:

sudo nano /etc/PHP.ini

Change the following lines:

memory_limit=256M
upload_max_filesize=64M
post_max_size=64M
upload_tmp_dir=/tmp

Save the file when you are finished.

3 Configure Database

MysqL_secure_installation script.

sudo MysqL_secure_installation

Answer all the questions as shown below:

Setrootpassword?[Y/n]Y
Newpassword:
Re-enternewpassword:
Removeanonymoususers?[Y/n]Y
Disallowrootloginremotely?[Y/n]Y
Removetestdatabaseandaccesstoit?[Y/n]Y
Reloadprivilegetablesnow?[Y/n]Y

MysqL shell and create a database and user for Cerb:

MysqL -u root -p

Enter your root password and press Enter,then create a database and user with the following command:

MariaDB [(none)]> CREATE DATABASE curbdb;
MariaDB [(none)]> GRANT ALL PRIVILEGES ON curbdb.* TO 'cerb'@'localhost' IDENTIFIED BY 'cerbpassword';
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> \q

4 Install Cerb

Once Database is configured,you will need to install Cerb. You can download the latest version of Cerb from GitHub repository with the following command:

cd /var/www/html/
sudo git clone git://github.com/wgm/cerb.git cerb

sudo chown -R apache:apache cerb
sudo chmod -R 777 cerb

5 Configure Apache for Cerb

sudo nano /etc/httpd/conf.d/cerb.conf

Add the following lines:

<VirtualHost*:80>
ServerAdminadmin@example.com
DocumentRoot"/var/www/html/cerb.conf"
ServerNameyour-server-ip
ErrorLog"/var/log/httpd/cerb-error_log"
CustomLog"/var/log/httpd/cerb-access_log"combined
<Directory"/var/www/html/cerb/">
OptionsIndexesMultiViewsFollowSymlinks
AllowOverrideAll
Orderallow,deny
Allowfromall
</Directory>
</VirtualHost>

Save and close the file when you are finished,then restart Apache service:

sudo systemctl restart httpd

6 Access Cerb Web Interface

Before accessing Cerb web interface,you will need to allow HTTP traffic on port 80 through the system firewalld.

sudo firewall-cmd --zone=public --permanent --add-service=http
sudo firewall-cmd --reload

Now open your web browser and type the URL http://your-server-ip,then complete all required steps to finish the installation.

Once Cerb is installed,delete the install directory before using it with the following command:

sudo rm -rf /var/www/html/cerb/install

That's it,you can now easily access and use Cerb through your web browser.

7 Links

原文链接:https://www.f2er.com/centos/378103.html

猜你在找的CentOS相关文章