{"id":1,"date":"2019-12-10T04:38:57","date_gmt":"2019-12-10T04:38:57","guid":{"rendered":"http:\/\/neoporcupine.mine.nu\/blog\/?p=1"},"modified":"2019-12-10T08:58:22","modified_gmt":"2019-12-10T08:58:22","slug":"hello-world","status":"publish","type":"post","link":"http:\/\/neoporcupine.net\/blog\/index.php\/2019\/12\/10\/hello-world\/","title":{"rendered":"Hello world!"},"content":{"rendered":"\n<p>This is the first post 2019-12-10 since the nightmare of installing WordPress on a fresh version of Ubuntu Server 19.10.<\/p>\n\n<p>So you have installed the latest version of Ubuntu Server on your cheap NUC, done some port forwarding and you&#8217;re all LAMPed up. The WordPress guide at Ubuntu will mess you up, lead you away from solutions. Google will help. The wordpress forum has some good information buried deep, as does stack exchange. It is all simple, but esoteric, hard to find. There are well intentioned postings that want you to do very bad things, so be careful picking and choosing.<\/p>\n\n<p><\/p><pre style=\"font-size:0.8em\"><code>\n# su is naughty, so either you will use it, or you prefix sudo to all cmds\nsu\n### LAMP\napt install lamp-server^\n# Now fiddle with PHP.ini\nnano \/etc\/php\/7.3\/apache2\/php.ini\n# Now fiddle with MySQL.cnf\nnano \/etc\/mysql\/mysql.conf.d\/mysqld.cnf\n# restart all the things\nsystemctl restart apache2\nsystemctl restart mysql\n\n### WordPress\napt install wordpress\n# \/var\/lib\/wordpress\/\n# \/usr\/share\/wordpress\/\n# Edit the wordpress site file\n# This places wordpress in a virtual folder off your site. \/blog\nnano \/etc\/apache2\/sites-available\/wordpress.conf\n#--- File: \/etc\/apache2\/sites-available\/wordpress.conf\nAlias \/blog \/usr\/share\/wordpress\n&lt;Directory \/usr\/share\/wordpress&gt;\n\tOptions FollowSymLinks\n\tAllowOverride Limit Options FileInfo\n\tDirectoryIndex index.php\n\tOrder allow,deny\n\tAllow from all\n&lt;\/Directory&gt;\n&lt;Directory \/usr\/share\/wordpress\/wp-content&gt;\n\tOptions FollowSymLinks\n\tOrder allow,deny\n\tAllow from all\n&lt;\/Directory&gt;\n#--- END File: \/etc\/apache2\/sites-available\/wordpress.conf\n\n# Enable the site\nsudo a2ensite wordpress\nsystemctl reload apache2\n# WordPress config file\ncp \/usr\/share\/wordpress\/wp-config-sample.php \/etc\/wordpress\/config-default.php\nnano \/etc\/wordpress\/config-default.php\n#--- File: \/etc\/wordpress\/config-default.php\n# Edit all the settings you can with your setup details.\n# Assuming your username and database are wordpress (see SQL below)\n\/** The name of the database for WordPress *\/\ndefine( 'DB_NAME', 'wordpress' );\n\/** MySQL database username *\/\ndefine( 'DB_USER', 'wordpress' );\n\/** MySQL database password *\/\ndefine( 'DB_PASSWORD', 'yourpasswordhere' );\n\/** MySQL hostname *\/\ndefine( 'DB_HOST', 'localhost' );\n\/** Database Charset to use in creating database tables. *\/\ndefine( 'DB_CHARSET', 'utf8' );\n\/** The Database Collate type. Don't change this if in doubt. *\/\ndefine( 'DB_COLLATE', '' );\n\/** Trying to avoid stupid FTP *\/\ndefine( 'FS_METHOD', 'direct' );\n#--- END File: \/etc\/wordpress\/config-default.php\n\n# Permissions for wordpress to import files, themes, etc\n# You may have to add root to the www-data group\nchown root:www-data -R \/usr\/share\/wordpress\/wp-content\nchmod -R 775 \/usr\/share\/wordpress\/wp-content\n# Prep SQL\nmysql -u root\n#--- MySQL commands\nCREATE USER wordpress@localhost IDENTIFIED BY 'yourpasswordhere';\nALTER USER 'wordpress'@'localhost' IDENTIFIED WITH mysql_native_password BY 'yourpasswordhere';\nCREATE DATABASE wordpress;\nGRANT ALL PRIVILEGES ON wordpress.* TO wordpress@localhost;\nQUIT;\n#--- END MySQL\n\n# The remainder of the setup happens within WordPress\nhttp:\/\/your.blog.domain\/blog\n<\/code><\/pre><p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>This is the first post 2019-12-10 since the nightmare of installing WordPress on a fresh version of Ubuntu Server [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,9],"tags":[],"class_list":["post-1","post","type-post","status-publish","format-standard","hentry","category-linux","category-wp"],"_links":{"self":[{"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=1"}],"version-history":[{"count":6,"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1\/revisions"}],"predecessor-version":[{"id":27,"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/posts\/1\/revisions\/27"}],"wp:attachment":[{"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=1"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=1"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/neoporcupine.net\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=1"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}