User Tools

Site Tools


setupwordpressubuntu22

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
setupwordpressubuntu22 [2025/04/28 23:25] tektinkerssetupwordpressubuntu22 [2025/04/29 00:26] (current) tektinkers
Line 1: Line 1:
 +[[https://docs.tektinkers.com|TinkersDocs Home]]
 +[[https://www.tektinkers.com|Back to tektinkers.com]]
 +
 ====== Setup Wordpress - Ubuntu 22 ====== ====== Setup Wordpress - Ubuntu 22 ======
 \\ \\
Line 13: Line 16:
 **Installing Additional PHP Extensions:** **Installing Additional PHP Extensions:**
 \\ \\
 +<code>sudo apt install php-curl php-gd php-mbstring php-xml php-xmlrpc php-soap php-intl php-zip</code>
 +<code>sudo systemctl restart apache2</code>
 +\\
 +**Adjust Apache Config to allow overrides and rewrites in .htaccess**
 +\\
 +<code>sudo nano /etc/apache2/sites-available/wordpress.conf</code>
 +<code>
 +<VirtualHost *:80>
 +. . .
 +    <Directory /var/www/wordpress/>
 +        AllowOverride All
 +    </Directory>
 +. . .
 +</VirtualHost>
 +</code>
 +<code>sudo a2enmod rewrite</code>
 +<code>sudo apache2ctl configtest</code>
 +<code>sudo systemctl restart apache2</code>
 +\\
 +**Downloading Wordpress**
 +\\
 +<code>cd /tmp</code>
 +<code>curl -O https://wordpress.org/latest.tar.gz</code>
 +<code>tar xzvf latest.tar.gz</code>
 +<code>touch /tmp/wordpress/.htaccess</code>
 +<code>cp /tmp/wordpress/wp-config-sample.php /tmp/wordpress/wp-config.php</code>
 +<code>mkdir /tmp/wordpress/wp-content/upgrade</code>
 +//Change 2nd wordpress to name of directory to put wordpress in//
 +<code>sudo cp -a /tmp/wordpress/. /var/www/wordpress</code>
 +\\
 +**Configure Wordpress Directory**
 +\\
 +<code>sudo chown -R www-data:www-data /var/www/wordpress</code>
 +<code>sudo find /var/www/wordpress/ -type d -exec chmod 750 {} \;</code>
 +<code>sudo find /var/www/wordpress/ -type f -exec chmod 640 {} \;</code>
 +Copy salts to notepad for safekeeping temporarily
 +<code>curl -s https://api.wordpress.org/secret-key/1.1/salt/</code>
 +<code>sudo nano /var/www/wordpress/wp-config.php</code>
 +//Update file and add line//
 +<code>
 +. . .
  
 +// ** MySQL settings - You can get this info from your web host ** //
 +/** The name of the database for WordPress */
 +define( 'DB_NAME', 'wordpress' );
 +
 +/** MySQL database username */
 +define( 'DB_USER', 'wordpressuser' );
 +
 +/** MySQL database password */
 +define( 'DB_PASSWORD', 'password' );
 +
 +/** MySQL hostname */
 +define( 'DB_HOST', 'localhost' );
 +
 +/** 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('FS_METHOD', 'direct');
 +</code>
 +\\
 +**Complete Install from Web Interface**
 +\\
 +//From the web browser navigate to websites IP or URL//
 \\ \\
 \\ \\
 \\ \\
 Credit to: [[https://www.digitalocean.com/community/tutorials/how-to-install-wordpress-on-ubuntu-22-04-with-a-lamp-stack|https://www.digitalocean.com/community/tutorials/how-to-install-wordpress-on-ubuntu-22-04-with-a-lamp-stack]] Credit to: [[https://www.digitalocean.com/community/tutorials/how-to-install-wordpress-on-ubuntu-22-04-with-a-lamp-stack|https://www.digitalocean.com/community/tutorials/how-to-install-wordpress-on-ubuntu-22-04-with-a-lamp-stack]]
setupwordpressubuntu22.1745882731.txt.gz · Last modified: 2025/04/28 23:25 by tektinkers