{"id":262,"date":"2020-08-30T12:08:50","date_gmt":"2020-08-30T19:08:50","guid":{"rendered":"https:\/\/anilot.tk\/blog\/?p=262"},"modified":"2021-11-14T13:20:23","modified_gmt":"2021-11-14T21:20:23","slug":"update-caddy-2-web-server-step-by-step-guide","status":"publish","type":"post","link":"https:\/\/anilot.net\/blog\/index.php\/2020\/08\/30\/update-caddy-2-web-server-step-by-step-guide\/","title":{"rendered":"Update Caddy 2 Web Server &#8211; Step-by-Step Guide"},"content":{"rendered":"<div class='booster-block booster-read-block'>\n                <div class=\"twp-read-time\">\n                \t<i class=\"booster-icon twp-clock\"><\/i> <span>Read Time:<\/span>1 Minute, 25 Second                <\/div>\n\n            <\/div>\n<p class=\"has-drop-cap wp-block-paragraph\">Given Caddy 2 is a fairly young web server, the documentation around update existing the Caddy 2 installation is not very easy to find, especially when Caddy was not installed via any package manager. This guide aims to show you how to update Caddy to the latest version. If you have not installed Caddy, you can follow this guide to <a href=\"https:\/\/anilot.tk\/blog\/index.php\/2020\/06\/10\/install-caddy-2-web-server-on-ubuntu-20-04-guide\/\" target=\"_blank\" rel=\"noreferrer noopener\">install Caddy<\/a>. <\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Stop the Currently Running Caddy<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Before upgrading, we will have to stop the currently running Caddy. If you installed the Caddy server with the Daemon, you can stop the currently running instance by:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"shell\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">$ sudo systemctl stop caddy<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Download Latest Release<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Caddy is being updated often. You can find the latest release candidate in the official <a href=\"https:\/\/github.com\/caddyserver\/caddy\/releases\" target=\"_blank\" rel=\"noreferrer noopener\">Caddy git repo<\/a>. To check the current version of Caddy, you can run <code>$ caddy version<\/code>. The below use the Caddy 2.20 rc.1 as an example. Feel free to change it if another version is available for your platform.  <\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"shell\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">$ wget https:\/\/github.com\/caddyserver\/caddy\/releases\/download\/v2.2.0-rc.1\/caddy_2.2.0-rc.1_linux_arm64.tar.gz\n$ tar zxvf caddy_2.2.0-rc.1_linux_arm64.tar.gz\n$ rm caddy_2.2.0-rc.1_linux_arm64.tar.gz | rm LICENSE | rm README.md\n$ sudo mv caddy \/usr\/bin\/<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Update Caddy and Restart It<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">It is very straightforward to install the updated Caddy. Just run<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"shell\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">$ sudo mv caddy \/usr\/bin\/\n$ sudo systemctl start caddy\n$ caddy version<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If you see the new version is working and your web server is back online, congratulations! You&#8217;ve updated caddy to the latest version. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Hopefully this Caddy update guide is very simple to follow. Any questions? Feel free to leave a comment below. <\/p>\n        <div class=\"booster-block booster-reactions-block\">\n            <div class=\"twp-reactions-icons\">\n                \n                <div class=\"twp-reacts-wrap\">\n                    <a react-data=\"be-react-1\" post-id=\"262\" class=\"be-face-icons un-reacted\" href=\"javascript:void(0)\">\n                        <img decoding=\"async\" src=\"https:\/\/anilot.net\/blog\/wp-content\/plugins\/booster-extension\/\/assets\/icon\/happy.svg\" alt=\"Happy\">\n                    <\/a>\n                    <div class=\"twp-reaction-title\">\n                        Happy                    <\/div>\n                    <div class=\"twp-count-percent\">\n                                                    <span style=\"display: none;\" class=\"twp-react-count\">0<\/span>\n                        \n                                                <span class=\"twp-react-percent\"><span>0<\/span> %<\/span>\n                                            <\/div>\n                <\/div>\n\n                <div class=\"twp-reacts-wrap\">\n                    <a react-data=\"be-react-2\" post-id=\"262\" class=\"be-face-icons un-reacted\" href=\"javascript:void(0)\">\n                        <img decoding=\"async\" src=\"https:\/\/anilot.net\/blog\/wp-content\/plugins\/booster-extension\/\/assets\/icon\/sad.svg\" alt=\"Sad\">\n                    <\/a>\n                    <div class=\"twp-reaction-title\">\n                        Sad                    <\/div>\n                    <div class=\"twp-count-percent\">\n                                                    <span style=\"display: none;\" class=\"twp-react-count\">0<\/span>\n                                                                        <span class=\"twp-react-percent\"><span>0<\/span> %<\/span>\n                                            <\/div>\n                <\/div>\n\n                <div class=\"twp-reacts-wrap\">\n                    <a react-data=\"be-react-3\" post-id=\"262\" class=\"be-face-icons un-reacted\" href=\"javascript:void(0)\">\n                        <img decoding=\"async\" src=\"https:\/\/anilot.net\/blog\/wp-content\/plugins\/booster-extension\/\/assets\/icon\/excited.svg\" alt=\"Excited\">\n                    <\/a>\n                    <div class=\"twp-reaction-title\">\n                        Excited                    <\/div>\n                    <div class=\"twp-count-percent\">\n                                                    <span style=\"display: none;\" class=\"twp-react-count\">0<\/span>\n                                                                        <span class=\"twp-react-percent\"><span>0<\/span> %<\/span>\n                                            <\/div>\n                <\/div>\n\n                <div class=\"twp-reacts-wrap\">\n                    <a react-data=\"be-react-6\" post-id=\"262\" class=\"be-face-icons un-reacted\" href=\"javascript:void(0)\">\n                        <img decoding=\"async\" src=\"https:\/\/anilot.net\/blog\/wp-content\/plugins\/booster-extension\/\/assets\/icon\/sleepy.svg\" alt=\"Sleepy\">\n                    <\/a>\n                    <div class=\"twp-reaction-title\">\n                        Sleepy                    <\/div>\n                    <div class=\"twp-count-percent\">\n                                                    <span style=\"display: none;\" class=\"twp-react-count\">0<\/span>\n                        \n                                                <span class=\"twp-react-percent\"><span>0<\/span> %<\/span>\n                                            <\/div>\n                <\/div>\n\n                <div class=\"twp-reacts-wrap\">\n                    <a react-data=\"be-react-4\" post-id=\"262\" class=\"be-face-icons un-reacted\" href=\"javascript:void(0)\">\n                        <img decoding=\"async\" src=\"https:\/\/anilot.net\/blog\/wp-content\/plugins\/booster-extension\/\/assets\/icon\/angry.svg\" alt=\"Angry\">\n                    <\/a>\n                    <div class=\"twp-reaction-title\">Angry<\/div>\n                    <div class=\"twp-count-percent\">\n                                                    <span style=\"display: none;\" class=\"twp-react-count\">0<\/span>\n                                                                        <span class=\"twp-react-percent\"><span>0<\/span> %<\/span>\n                        \n                    <\/div>\n                <\/div>\n\n                <div class=\"twp-reacts-wrap\">\n                    <a react-data=\"be-react-5\" post-id=\"262\" class=\"be-face-icons un-reacted\" href=\"javascript:void(0)\">\n                        <img decoding=\"async\" src=\"https:\/\/anilot.net\/blog\/wp-content\/plugins\/booster-extension\/\/assets\/icon\/surprise.svg\" alt=\"Surprise\">\n                    <\/a>\n                    <div class=\"twp-reaction-title\">Surprise<\/div>\n                    <div class=\"twp-count-percent\">\n                                                    <span style=\"display: none;\" class=\"twp-react-count\">0<\/span>\n                                                                        <span class=\"twp-react-percent\"><span>0<\/span> %<\/span>\n                                            <\/div>\n                <\/div>\n\n            <\/div>\n        <\/div>\n\n    ","protected":false},"excerpt":{"rendered":"<p>Given Caddy 2 is a fairly young web server, the documentation around update existing the Caddy 2 installation is not very easy to find, especially&hellip;<\/p>\n","protected":false},"author":1,"featured_media":138,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"ai_generated_summary":"","_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[7],"tags":[11,12],"class_list":["post-262","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tech","tag-caddy","tag-web-server","has-post-thumbnail-archive"],"aioseo_notices":[],"jetpack_featured_media_url":"https:\/\/anilot.net\/blog\/wp-content\/uploads\/2020\/06\/63murhlf_400x400.jpg","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/posts\/262","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=262"}],"version-history":[{"count":3,"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/posts\/262\/revisions"}],"predecessor-version":[{"id":330,"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/posts\/262\/revisions\/330"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/media\/138"}],"wp:attachment":[{"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=262"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=262"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/anilot.net\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=262"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}