In this tutorial, we will see how to install the popular content management system called WordPress on one of our servers using the image with Ubuntu 16.04 and the latest version of VestaCP, a control panel that is very easy to use and lets you do everything you need on the server.
To install WordPress, we will need to have a server running VestaCP in our Clouding account. We will also need a domain to configure on our server, which we will later use to manage WordPress.
Preparation in VestaCP
First, open your preferred browser and access VestaCP, where we will log in with the username admin and the server password:
https://IP_servidor:8083Then go to Web > Añadir Web:
Once it has been created, click Web, hover over your domain and click Editar to configure your FTP account:
Now we will create the database that our WordPress installation will use. Go to BD > Añadir base de datos and fill in the details as follows (the database name and username may be different):
Finally, we will change the email address for the Admin user for actions we will perform later. Go to Usuario > Admin > Editar and change the Email field to an active email address:
Copying the WordPress files using a graphical interface
First, we will download WordPress and upload it to the server using Filezilla or another FTP program. We can download WordPress from the following link and connect to the server via FTP using the following details:
- Servidor: The IP address of your server running VestaCP
- Usuario: The one you created earlier, in our case admin_wp
- Contraseña: The one configured earlier
We will then copy the WordPress files from the left-hand column to the right-hand column:
Copying the WordPress files using the CLI
If you have basic Linux knowledge, it may be easier to perform this process using commands over an SSH connection to the server. First, connect to the server and navigate to the website directory:
cd /home/admin/web/tudominio/public_htmlDownload WordPress in tar.gz format:
wget https://wordpress.org/latest.tar.gzExtract it:
tar zxf latest.tar.gzDelete the compressed file and move the files to the correct directory:
rm -rf latest.tar.gz && mv wordpress/* .Then change the permissions:
chown admin.admin -R *
find . -type d -exec chmod 755 {} \;
find . -type f -exec chmod 644 {} \;Installing WordPress
Once we have completed the steps above, we will start installing WordPress and connect it to the database we created earlier. First, select the language:
After carefully reading the WordPress instructions, click ¡Vamos a ello! and continue with the configuration.
Now it is time to configure the database using the following details:
- Nombre de la base de datos: the name we configured earlier, in our case admin_miblog
- Nombre de usuario: the one we configured earlier, in our case admin_miblogu
- Contraseña: the one chosen when creating the database.
- Servidor de datos: localhost
- Prefijo de tabla: We can change the prefix if we want, although this is optional. Changing it will also make our database a little more secure.
If all the details entered are correct, we can proceed with installing WordPress:
Select the site name and other information, then click "Instalar WordPress":
We will now have finished installing WordPress on our server running VestaCP:
To access the WordPress administration panel, go to http://midominio.com/wp-admin and enter the username and password configured earlier.
Enabling SSL in WordPress
To enable an SSL certificate for our website from VestaCP, simply go to Web > Editar and enable the options Soportar SSL and Soportar Lets Encrypt, then click Guardar. Our SSL certificate will be enabled in about 5 minutes.
Now, in WordPress, access the panel and go to Ajustes > Generales and change the Dirección de WordPress and the Dirección del sitio by adding HTTPS:
With this done, we can now access our WordPress site at https://midominio.com.