Using a Different System?
-
How to Install TYPO3 CMS on CentOS 7
TYPO3 is a free and open source enterprise content management system. It is written in PHP and uses MySQL to store its data. TYPO3 is a responsive, mobile ready, multilingual and secure CMS. It can be easily customized and extended without writing any code.
In this tutorial, you will learn to install TYPO3 CMS on Ubuntu 16.04.
Prerequisites
- A Vultr Ubuntu 16.04 server instance.
- A sudo user.
Step 1: System update
Before installing any packages on the Ubuntu server instance, it is recommended to update the system. Log in using the sudo user and run the following commands to update the system.
sudo apt-get update
sudo apt-get -y upgrade
Step 2: Install Apache web server
Install the Apache web server.
sudo apt-get -y install apache2
Start Apache and enable it to automatically run at boot time.
sudo systemctl start apache2
sudo systemctl enable apache2
Step 3: Install PHP 7
Install the latest version of PHP along with the modules required by TYPO3.
sudo apt-get -y install php php-gd php-json php-mysqli php-curl php-cli php-apcu php-soap php-xml php-zip php-mbstring libfreetype6 php-bcmath php-fileinfo imagemagick
Configure php.ini
using any text editor of your choice.
sudo nano /etc/php/7.0/apache2/php.ini
Find the following lines and change their values according to the instructions provided.
max_execution_time = 30 // change it to 240
; max_input_vars = 1000 // Uncomment and change the value to 1500
Step 4: Install MySQL
Install MySQL database server.
sudo apt-get -y install mysql-server
Start MySQL server and enable it to automatically start at boot time.
sudo systemctl start mysql
sudo systemctl enable mysql
Secure your MySQL installation.
sudo mysql_secure_installation
You will be asked for the current MySQL root password. Provide the root password set during installation and answer “Y” to all of the questions asked. The questions asked are self-explanatory.
Step 5: Create database for TYPO3
Log into the MySQL shell as the root user by running the following command.
mysql -u root -p
Provide the password for the MySQL root user to log in.
Run the following queries to create a database and a database user for TYPO3.
CREATE DATABASE typo3_data CHARACTER SET utf8 COLLATE utf8_general_ci;
CREATE USER 'typo3_user'@'localhost' IDENTIFIED BY 'StrongPassword';
GRANT ALL PRIVILEGES ON typo3_data.* TO 'typo3_user'@'localhost';
FLUSH PRIVILEGES;
EXIT;
You can replace the database name typo3_data
and username typo3_user
according to your choice. Be sure to change StrongPassword
to a very strong password.
Step 6: Install TYPO3
Switch to the Apache web root directory by running:
cd /var/www
Download the TYPO3 archive using:
sudo wget https://get.typo3.org/8.7.3 -O typo3.tar.gz
You can always find the link to the latest version of software on the TYPO3 download page.
Extract the archive:
sudo tar xzf typo3.tar.gz
Rename the extracted directory for convenience.
sudo mv typo3*/ typo3/
Rename the .htaccess
file by running:
sudo mv typo3/_.htaccess typo3/.htaccess
Create an empty file with filename FIRST_INSTALL
. The web installer checks for this file before starting the installation.
sudo touch /var/www/typo3/FIRST_INSTALL
Provide the appropriate ownership by running:
sudo chown -R www-data:www-data /var/www/typo3
Step 7: Create virtual host
Run the following command to create a virtual host for your TYPO3 site.
sudo nano /etc/apache2/sites-available/cms.example.com.conf
Populate the file with:
<VirtualHost *:80>
ServerName cms.example.com
DocumentRoot /var/www/typo3
<Directory /var/www/typo3>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
allow from all
</Directory>
</VirtualHost>
Activate the configuration by running.
sudo a2ensite cms.example.com.conf
Restart Apache.
sudo systemctl restart apache2
Step 8: Finish installation
Your TYPO3 CMS installation is now complete. You can finish configuring TYPO3 through your web browser. Open your web browser and navigate to the URL http://cms.example.com
with the actual domain name pointed towards your Vultr VPS.
Want to contribute?
You could earn up to $300 by adding new articles
Suggest an update
Request an article