How to install WordPress with Nginx on FreeBSD

How to install WordPress with Nginx and Let’s Encrypt SSL on FreeBSD

In this FreeBSD tutorial, we will learn how to install WordPress using an Apache web server with SSL from Let’s Encrypt for HTTPS.

Install Nginx

Install Nginx web server.

Enable the nginx service.

Run the nginx service.

Browse http://serverIP to check if the Nginx web server is running properly.

Configure Server Block

Next, configure the Nginx server block for the musaamin.my.id domain.

Create a folder for the document root.

Create a folder to store block server configuration files.

Create a server block configuration file.

Fill in the server block configuration file.

Open the Nginx configuration file.

Add the configuration below before closing http.

Check for configuration errors.

If there is no mistake.

Restart the nginx service.

Browse http://musaamin.my.id.

Install PHP

Install PHP 7.4 and its extensions.

Open the PHP-FPM configuration file.

Activate and adjust the following configurations.

Create a php.ini file

Open the php.ini file.

Options activated and changed.

Enable and run the php-fpm service.

Configure the server block to read PHP scripts.

Change the configuration to be like below.

Nginx configuration test.

Restart the nginx service

Create the info.php file.

Browse http://musaamin.my.id/info.php

Install SSL Let’s Encrypt

Install Let’s Encrypt certbot for Nginx.

Request SSL for the musaamin.my.id domain.

If successful, certbot changes the server block configuration file.

Isinya.

Browse https://musaamin.my.id.

Install MariaDB

Install MariaDB database.

Enable and run the MariaDB service.

Secure MariaDB installation.

Answer the question.

Login to MariaDB.

Create a database for WordPress.

Install WordPress

Download the latest WordPress.

Extract wordpress.tar.gz

Copy the contents of the wordpress folder to the document root.

Change ownership.

Delete the index.html and info.php files created earlier.

Browse https://musaamin.my.id to install WordPress.

  • Continue
  • Let’s go!
  • Enter the database name, username, and password that was created in MariaDB. For Database Host = 127.0.0.1. Submit
  • Run the installation
  • Enter the site title, username, password and email. Install WordPress.

WordPress has finished installing.

Cek https://musaamin.my.id and login to the dashboard.

Free credit $100 for new account at Vultr. Register now

Good luck 🙂

Support this blog by making a donation via PayPal.me/musaamin

Default image
Musa Amin
I am a Linux System Administrator and also write many tutorials about Linux, Cloud, and Open Source. Hire me via email hai[at]musaamin.web.id.
Articles: 728

Leave a Reply