Meine kleine Dokumentation

Die Installationsdokumentation zu MeineKleineFarm.net

Benutzer-Werkzeuge

Webseiten-Werkzeuge


waffeln_am_ententeich

Unterschiede

Hier werden die Unterschiede zwischen zwei Versionen angezeigt.

Link zu dieser Vergleichsansicht

Beide Seiten der vorigen RevisionVorhergehende Überarbeitung
Nächste Überarbeitung
Vorhergehende Überarbeitung
Letzte ÜberarbeitungBeide Seiten der Revision
waffeln_am_ententeich [2016/10/05 22:04] xenadminwaffeln_am_ententeich [2016/11/04 22:43] xenadmin
Zeile 1: Zeile 1:
-====== Überschrift ====== +====== Wordpress Blog: waffeln-am-ententeich.de ====== 
-Apache2 und PHP5 sind bereits installiert+ 
 +Apache2, MySQL und PHP5 sind bereits installiert -> [[basics|Basics]]
 <code bash> <code bash>
 apt update apt update
-apt install mysql-server -y +apt install php5-mysql -y 
-<mysql root@localhost Passwort setzen> +mysql -u root -p
-mysql_secure_installation +
-</code> +
-  * <code>NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL +
-      SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY! +
- +
-In order to log into MySQL to secure it, we'll need the current +
-password for the root user.  If you've just installed MySQL, and +
-you haven't set the root password yet, the password will be blank, +
-so you should just press enter here. +
- +
-Enter current password for root (enter for none): +
-ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES) +
-Enter current password for root (enter for none): +
-OK, successfully used password, moving on... +
- +
-Setting the root password ensures that nobody can log into the MySQL +
-root user without the proper authorisation. +
- +
-You already have a root password set, so you can safely answer 'n'+
- +
-Change the root password? [Y/n] n +
- ... skipping. +
- +
-By default, a MySQL installation has an anonymous user, allowing anyone +
-to log into MySQL without having to have a user account created for +
-them.  This is intended only for testing, and to make the installation +
-go a bit smoother.  You should remove them before moving into a +
-production environment. +
- +
-Remove anonymous users? [Y/n] y +
- ... Success! +
- +
-Normally, root should only be allowed to connect from 'localhost' This +
-ensures that someone cannot guess at the root password from the network. +
- +
-Disallow root login remotely? [Y/n] y +
- ... Success! +
- +
-By default, MySQL comes with a database named 'test' that anyone can +
-access.  This is also intended only for testing, and should be removed +
-before moving into a production environment. +
- +
-Remove test database and access to it? [Y/n] y +
- Dropping test database... +
-ERROR 1008 (HY000) at line 1: Can't drop database 'test'; database doesn't exist +
- ... Failed!  Not critical, keep moving... +
- - Removing privileges on test database... +
- ... Success! +
- +
-Reloading the privilege tables will ensure that all changes made so far +
-will take effect immediately. +
- +
-Reload privilege tables now? [Y/n] y +
- ... Success! +
- +
-Cleaning up... +
- +
-All done!  If you've completed all of the above steps, your MySQL +
-installation should now be secure. +
- +
-Thanks for using MySQL!+
 </code> </code>
-<code+<code mysql>
-mysql -u root -p+
 CREATE DATABASE wp_waffelente; CREATE DATABASE wp_waffelente;
 CREATE USER wp_waffelente@localhost IDENTIFIED BY 'PASSW0RD1'; CREATE USER wp_waffelente@localhost IDENTIFIED BY 'PASSW0RD1';
Zeile 74: Zeile 13:
 FLUSH PRIVILEGES; FLUSH PRIVILEGES;
 exit exit
 +</code>
 +<code bash>
 service apache2 restart && service mysql restart service apache2 restart && service mysql restart
  
Zeile 83: Zeile 24:
 chown -R www-data:www-data /var/www/html/waffeln-am-ententeich.de/root chown -R www-data:www-data /var/www/html/waffeln-am-ententeich.de/root
 chmod -R 755 /var/www/html/waffeln-am-ententeich.de/root chmod -R 755 /var/www/html/waffeln-am-ententeich.de/root
 +rm latest-de_DE.zip
  
 cp /var/www/html/waffeln-am-ententeich.de/root/wp-config-sample.php /var/www/html/waffeln-am-ententeich.de/root/wp-config.php cp /var/www/html/waffeln-am-ententeich.de/root/wp-config-sample.php /var/www/html/waffeln-am-ententeich.de/root/wp-config.php
 nano /var/www/html/waffeln-am-ententeich.de/root/wp-config.php nano /var/www/html/waffeln-am-ententeich.de/root/wp-config.php
 </code> </code>
 +<hidden wp-config.php -edit>
 <file php wp-config.php> <file php wp-config.php>
 <?php <?php
Zeile 106: Zeile 49:
 define('LOGGED_IN_SALT',   'Füge hier deine Zeichenkette ein'); define('LOGGED_IN_SALT',   'Füge hier deine Zeichenkette ein');
 define('NONCE_SALT',       'Füge hier deine Zeichenkette ein'); define('NONCE_SALT',       'Füge hier deine Zeichenkette ein');
 +</file>
 +</hidden>\\
 +Certificate Request und 4096 RSA Key mit [[http://xca.sourceforge.net/|XCA]] erstellt. Certificate bei [[https://startssl.com|StartSSL]] beantragt. Anschließend im Dateisystem speichern. 
 +<code bash>
 +nano /etc/ssl/certs/waffeln.meinekleinefarm.net.pem
 +nano /etc/ssl/private/waffeln.meinekleinefarm.net.key
  
-$table_prefix  = 'wp_'; +nano /etc/apache2/sites-available/waffeln.meinekleinefarm.net.conf 
-define('WP_DEBUG', false); +</code> 
-if ( !defined('ABSPATH') ) +<hidden waffeln.meinekleinefarm.net.conf -edit> 
-        define('ABSPATH', dirname(__FILE__) '/'); +<file apache waffeln.meinekleinefarm.net.conf> 
-require_once(ABSPATH 'wp-settings.php');+<VirtualHost *:80> 
 +        ServerName waffeln.meinekleinefarm.net 
 +        Redirect permanent / https://waffeln.meinekleinefarm.net
 +</VirtualHost> 
 + 
 +<IfModule mod_ssl.c> 
 +        <VirtualHost *:443> 
 +                ServerAdmin [email protected] 
 +                ServerName waffeln.meinekleinefarm.net 
 +                ServerAlias waffeln.meinekleinefarm.net 
 + 
 +                DocumentRoot /var/www/html/waffeln-am-ententeich.de/root/ 
 + 
 +                <Directory /var/www/html/waffeln-am-ententeich.de/root/> 
 +                        AllowOverride All 
 +                </Directory> 
 + 
 +                ErrorLog ${APACHE_LOG_DIR}/error.log 
 +                CustomLog ${APACHE_LOG_DIR}/access.log combined 
 + 
 +                SSLEngine on 
 +                SSLCertificateFile      /etc/ssl/certs/waffeln.meinekleinefarm.net.pem 
 +                SSLCertificateKeyFile   /etc/ssl/private/waffeln.meinekleinefarm.net.key 
 +                SSLCertificateChainFile /etc/ssl/certs/startcom_class1.pem 
 + 
 +                <FilesMatch "\.(cgi|shtml|phtml|php)$"> 
 +                                SSLOptions +StdEnvVars 
 +                </FilesMatch> 
 +                <Directory /usr/lib/cgi-bin> 
 +                                SSLOptions +StdEnvVars 
 +                </Directory> 
 + 
 +                BrowserMatch "MSIE [2-6]" \ 
 +                                nokeepalive ssl-unclean-shutdown \ 
 +                                downgrade-1.0 force-response-1.0 
 +                BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown 
 + 
 +        </VirtualHost> 
 +</IfModule>
 </file> </file>
 +</hidden>\\
 +<code bash>
 +a2ensite waffeln.meinekleinefarm.net.conf
 +service apache2 reload
 +</code>
 +Wordpress 5-minute Setup im Browser aufrufen und fertig stellen.\\
 +https://www.example.com/wp-admin/install.php\\
 +Username\\
 +Password\\
 +E-Mail\\
 +-> Fertig!
 +
 +FIXME
 +  * Secure Wordpress, Theme & PlugIn Updates
 +  * Filesystem Permissions
waffeln_am_ententeich.txt · Zuletzt geändert: 2016/11/09 19:48 von xenadmin