{"id":99,"date":"2020-05-13T20:18:49","date_gmt":"2020-05-14T01:18:49","guid":{"rendered":"https:\/\/donaldfcooley.info\/?p=99"},"modified":"2021-11-10T19:37:33","modified_gmt":"2021-11-11T01:37:33","slug":"upgrading-wordpress-on-openbsd-and-httpd","status":"publish","type":"post","link":"https:\/\/donaldfcooley.info\/?p=99","title":{"rendered":"Upgrading WordPress on OpenBSD and httpd"},"content":{"rendered":"\n<p>When I first setup WordPress on OpenBSD I followed Michael W. Lucas&#8217;s book, &#8220;Httpd and Relayd&#8221;.  Actually,  this was my first experience ever setting up WordPress on any server. The steps Michael gave made setting it up straightforward. But, when there was an update to WordPress 5.3 yesterday, I felt a bit nervous. I couldn&#8217;t find a howto or tutorial on how to upgrade WordPress in a chroot.<\/p>\n\n\n\n<p>httpd on OpenBSD runs in a chroot. I thought this would prove to be a huge problem but it wasn&#8217;t too difficult to update.<\/p>\n\n\n\n<p>In addition to Michael&#8217;s book mentioned above, the WordPress documentation on doing a manual upgrade was also helpful.<\/p>\n\n\n\n<figure class=\"wp-block-embed is-type-wp-embed is-provider-wordpress-org-forums wp-block-embed-wordpress-org-forums\"><div class=\"wp-block-embed__wrapper\">\nhttps:\/\/wordpress.org\/support\/article\/updating-wordpress\/#manual-update\n<\/div><\/figure>\n\n\n\n<p>I adapted the above instructions from WordPress&#8217;s to the fact that WordPress runs in a chroot on OpenBSD.<\/p>\n\n\n\n<p>To begin with, I downloaded the latest updated stable code from WordPess.<\/p>\n\n\n\n<p>ftp https:\/\/wordpress.org\/latest.tar.gz<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">Unpack the gzipped tarball and remove the old&nbsp;<code>wp-includes<\/code>&nbsp;and&nbsp;<code>wp-admin<\/code>&nbsp;directories\n<\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>tar -xzf latest.tar.gz\ndoas rm -r \/var\/www\/htdocs\/wp-includes\/ \/var\/www\/htdocs\/wp-admin\/\n<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-preformatted\">Now, update all the files without removing your own content.<\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>doas rsync --update -ra --progress wordpress\/ \/var\/www\/htdocs\/<\/code><\/pre>\n\n\n\n<p>All of our fresh files from WordPress are in place. Let&#8217;s fix the permissions on those files.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>doas chown -R www:www \/var\/www\/htdocs<\/code><\/pre>\n\n\n\n<p>That&#8217;s all I needed to do. I have a simple setup. Your mileage may vary.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>When I first setup WordPress on OpenBSD I followed Michael W. Lucas&#8217;s book, &#8220;Httpd and Relayd&#8221;. Actually, this was my first experience ever setting up WordPress on any server. The steps Michael gave made setting it up straightforward. But, when there was an update to WordPress 5.3 yesterday, I felt a bit nervous. I couldn&#8217;t &hellip; <a href=\"https:\/\/donaldfcooley.info\/?p=99\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Upgrading WordPress on OpenBSD and httpd<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[37,36,34,35],"class_list":["post-99","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-chroot","tag-httpd","tag-openbsd","tag-wordpress"],"_links":{"self":[{"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=\/wp\/v2\/posts\/99","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=99"}],"version-history":[{"count":12,"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=\/wp\/v2\/posts\/99\/revisions"}],"predecessor-version":[{"id":205,"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=\/wp\/v2\/posts\/99\/revisions\/205"}],"wp:attachment":[{"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=99"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=99"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/donaldfcooley.info\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=99"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}