WordPress
WordPress is one of the most popular online publishing platforms for building blogs and websites. Ease of use, extensive customization, and the ability to install countless themes, extensions, and plugins are among this content management system's features. Reasons for WordPress's popularity include its up-to-date framework development, many features, flexibility, ability to publish quickly in several languages, support for multiple authors, and its thriving user community.
One-Click Deployment
With Arvancloud Cloud Container ready-made applications, you can set up WordPress with just one click.
The WordPress ready-made application includes three pieces of software: WordPress, a MySQL database, and the phpMyAdmin database management panel. This means everything you need to set up a WordPress site is in this ready-made application.
To run the WordPress ready-made application, you need to choose a password for MySQL during its creation.
Setting up and running this application may take a few minutes. You can check the application's logs until it's fully set up.
Using WordPress
After setting up WordPress on the Arvancloud Cloud Container, you can access it through the free Arvancloud domain or connect it to your own domain, find the plugins you want, and build and publish a powerful WordPress website.
After choosing the language, username, and password and entering your email, you can access the WordPress dashboard.
Setting Up a Custom Domain
To connect your own domain to the application, you need to take the following two steps:
-
Change the address in the WordPress settings: In Settings, change the WordPress Address (URL) and Site Address (URL) fields to the domain/subdomain you want WordPress to run on.
When you apply this change, WordPress becomes inaccessible to you, and after applying the settings in step two, you can access WordPress through your own domain.
-
Set the custom domain in the Arvancloud Cloud Container panel: After changing the website name in WordPress, you need to connect the domain to the application through the application's domain settings in the Arvancloud Cloud Container panel.
You can now access WordPress through your own domain/subdomain.
Installing Popular Plugins
WordPress extensions or plugins are one of this CMS's most important advantages. With this feature, you can easily install many programs on WordPress and meet your website's needs. To do this, simply go to Plugins in the WordPress dashboard and review or search for plugins in Add New, then install them.
For example, by searching these extensions, you can install Elementor and easily design and publish a website with drag and drop.
Installing Arvancloud Plugins
For integration with and management of other Arvancloud services, you can install the Object Storage, CDN, and Video Platform WordPress plugins. To do this, simply search for "ArvanCloud" in Plugins and click Install Now.
The connection between Arvancloud Object Storage buckets and this extension is established by adding the following code snippet to the wp-config.php file:
define( 'ARVANCLOUD_STORAGE_SETTINGS', json_encode( array(
'access-key' => 'YOUR-ACCESS-KEY',
'secret-key' => 'YOUR-SECRET-KEY',
'endpoint-url' => 'https://s3.ir-[REGION].arvanstorage.ir',
) ) );
For this, you can see the wp-config.php settings guide.
Installing a Backup Plugin
One of the most important steps in implementing and keeping a website's data secure is backup. Many plugins are available for backing up WordPress, each offering different features. One of the most complete backup plugins is WPvivid Backup for MainWP, which you can install and set up by searching in Plugins.
Installing the WP-Matomo Integration Plugin
Matomo is an open-source web analytics tool with features such as reporting and analyzing user behavior, real-time visitor data updates, website page performance reports, event tracking, marketing campaign reports, and more. To get analysis of your WordPress website's user behavior, you can install this application with one click on the Arvancloud Cloud Container and connect it to WordPress.
To do this, use the WP-Matomo Integration plugin, and after installing and activating it, configure it to connect to the Matomo application in your namespace: set the Matomo URL to your Matomo application's address and enter the Matomo auth token.
Setting Up Redis
To cache services and optimize your WordPress website's load, you can use Redis. You can install this tool with just one click on the Arvancloud Cloud Container and easily connect it to WordPress with the Redis Object Cache extension. To connect the Redis ready-made application to WordPress, simply add the following code snippet to the wp-config.php file:
define( 'WP_REDIS_HOST', 'redis' );
define( 'WP_REDIS_PORT', 6379 );
For this, you can use the wp-config.php settings guide.
Then, in the WordPress dashboard, go to the Redis Object Cache settings and click Enable Object Cache so your WordPress site's content is cached.
wp-config.php Settings
The wp-config file contains the settings and configuration of MySQL, WordPress, authentication values, and WordPress's connection to other applications. You can edit this file through the WordPress application's console in the Arvancloud panel.
For example, to be able to update WordPress by pulling a new tag of its image, simply add the following line to the wp-config.php file:
define('FS_METHOD','direct');
With this setting, whenever you need to update the WordPress version, you can change its tag to the version you want in the WordPress application's settings.
To edit the wp-config.php file, first get the file's current content through the console with the following command:
cat wp-config.php
Then copy it into Notepad or any other text editor and make the needed changes. Finally, copy the new content and enter the following command in the application's console:
cat > wp-config.php
Now paste the new content and press CTRL and D to exit.
The new content should be similar to the following file:
<?php
define('WP_CACHE', true);
/**
* The base configuration for WordPress
*
* The wp-config.php creation script uses this file during the
* installation. You don't have to use the web site, you can
* copy this file to "wp-config.php" and fill in the values.
*
* This file contains the following configurations:
*
* * MySQL settings
* * Secret keys
* * Database table prefix
* * ABSPATH
*
* @link https://wordpress.org/support/article/editing-wp-config-php/
*
* @package WordPress
*/
define( 'WP_REDIS_HOST', 'redis' );
define( 'WP_REDIS_PORT', 6379 );
define( 'ARVANCLOUD_STORAGE_SETTINGS', json_encode( array(
'access-key' => 'YOUR-ACCESS-KEY',
'secret-key' => 'YOUR-SECRET-KEY',
'endpoint-url' => 'https://s3.ir-[REGION].arvanstorage.ir',
) ) );
define('FS_METHOD','direct');
// ** MySQL settings - You can get this info from your web host ** //
/** The name of the database for WordPress */
define( 'DB_NAME', 'wordpressdb');
/** MySQL database username */
define( 'DB_USER', 'root');
/** MySQL database password */
define( 'DB_PASSWORD', '110110');
/** MySQL hostname */
define( 'DB_HOST', 'wordpress-mysql-svc');
/** Database Charset to use in creating database tables. */
define( 'DB_CHARSET', 'utf8');
/** The Database Collate type. Don't change this if in doubt. */
define( 'DB_COLLATE', '');
define('WP_CACHE_KEY_SALT', 'example.ir');
/**#@+
* Authentication Unique Keys and Salts.
*
* Change these to different unique phrases!
* You can generate these using the {@link https://api.wordpress.org/secret-key/1.1/salt/ WordPress.org secret-key service}
* You can change these at any point in time to invalidate all existing cookies. This will force all users to have to log in again.
*
* @since 2.6.0
*/
define( 'AUTH_KEY', 'ebcc208a131704cee941db1504c6054c97ae701e');
define( 'SECURE_AUTH_KEY', 'ebcc208a131704cee941db1504c6054c97ae701e');
define( 'LOGGED_IN_KEY', '3526b6133c2aed16e5a682642fc969cb9f5f4ccb');
define( 'NONCE_KEY', 'ebcc208a131704cee941db1504c6054c97ae701e');
define( 'AUTH_SALT', 'ebcc208a131704cee941db1504c6054c97ae701e');
define( 'SECURE_AUTH_SALT', '3526b6133c2aed16e5a682642fc969cb9f5f4ccb');
define( 'LOGGED_IN_SALT', '3526b6133c2aed16e5a682642fc969cb9f5f4ccb');
define( 'NONCE_SALT', '3526b6133c2aed16e5a682642fc969cb9f5f4ccb');
/**#@-*/
/**
* WordPress Database Table prefix.
*
* You can have multiple installations in one database if you give each
* a unique prefix. Only numbers, letters, and underscores please!
*/
$table_prefix = 'wp_';
/**
* For developers: WordPress debugging mode.
*
* Change this to true to enable the display of notices during development.
* It is strongly recommended that plugin and theme developers use WP_DEBUG
* in their development environments.
*
* For information on other constants that can be used for debugging,
* visit the documentation.
*
* @link https://wordpress.org/support/article/debugging-in-wordpress/
*/
define( 'WP_DEBUG', false );
// If we're behind a proxy server and using HTTPS, we need to alert WordPress of that fact
// see also http://codex.wordpress.org/Administration_Over_SSL#Using_a_Reverse_Proxy
if (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] === 'https') {
$_SERVER['HTTPS'] = 'on';
}
/* That's all, stop editing! Happy publishing. */
/** Absolute path to the WordPress directory. */
if ( ! defined( 'ABSPATH' ) ) {
define( 'ABSPATH', __DIR__ . '/' );
}
/** Sets up WordPress vars and included files. */
require_once ABSPATH . 'wp-settings.php';
Note that the file above contains sample values, and for your application you must use the original content of wp-config.php.