From 3366384d9347447632ac334ffbbe35fb18738b90 Mon Sep 17 00:00:00 2001 From: Matt Holt Date: Tue, 19 Jan 2021 18:45:49 -0700 Subject: caddycmd: Add upgrade command (#3972) Replaces the current Caddy executable with a new one from the build server. Honors custom builds, as long as plugins are registered on the Caddy website. Requires permissions to replace current executable, of course. This is an experimental command that may get changed or removed later. --- cmd/commands.go | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'cmd/commands.go') diff --git a/cmd/commands.go b/cmd/commands.go index e4a2b91..1765194 100644 --- a/cmd/commands.go +++ b/cmd/commands.go @@ -277,6 +277,15 @@ is always printed to stdout.`, }(), }) + RegisterCommand(Command{ + Name: "upgrade", + Func: cmdUpgrade, + Short: "Upgrade Caddy (EXPERIMENTAL)", + Long: ` +Downloads an updated Caddy binary with the same modules/plugins at the +latest versions. EXPERIMENTAL: May be changed or removed.`, + }) + } // RegisterCommand registers the command cmd. -- cgit v1.2.3