summaryrefslogtreecommitdiffstats
path: root/usr.sbin
diff options
context:
space:
mode:
authorcperciva <cperciva@FreeBSD.org>2015-10-16 01:23:41 +0000
committercperciva <cperciva@FreeBSD.org>2015-10-16 01:23:41 +0000
commitac728f85ceeee64c6916aedaaf57cd52d0001429 (patch)
treef4c1c75e5307a87c68ba69e9d8b43d35af9c023c /usr.sbin
parentb46146d7b72da58a889ee051e085a3f4a6d1aaaf (diff)
downloadFreeBSD-src-ac728f85ceeee64c6916aedaaf57cd52d0001429.zip
FreeBSD-src-ac728f85ceeee64c6916aedaaf57cd52d0001429.tar.gz
MFC r289065: Add --currently-running <release> option to freebsd-update.
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/freebsd-update/freebsd-update.85
-rw-r--r--usr.sbin/freebsd-update/freebsd-update.sh5
2 files changed, 10 insertions, 0 deletions
diff --git a/usr.sbin/freebsd-update/freebsd-update.8 b/usr.sbin/freebsd-update/freebsd-update.8
index 02b9b00..a9caff6 100644
--- a/usr.sbin/freebsd-update/freebsd-update.8
+++ b/usr.sbin/freebsd-update/freebsd-update.8
@@ -113,6 +113,11 @@ Please do not run
.Nm Cm fetch
from crontab or similar using this flag, see:
.Nm Cm cron
+.It Fl -currently-running Ar release
+Don't detect the currently-running release; instead, assume that the
+system is running the specified
+.Ar release .
+This is most likely to be useful when upgrading jails.
.El
.Sh COMMANDS
The
diff --git a/usr.sbin/freebsd-update/freebsd-update.sh b/usr.sbin/freebsd-update/freebsd-update.sh
index 19d5198..9fcc012 100644
--- a/usr.sbin/freebsd-update/freebsd-update.sh
+++ b/usr.sbin/freebsd-update/freebsd-update.sh
@@ -52,6 +52,8 @@ Options:
(default: root)
--not-running-from-cron
-- Run without a tty, for use by automated tools
+ --currently-running release
+ -- Update as if currently running this release
Commands:
fetch -- Fetch updates from server
cron -- Sleep rand(3600) seconds, fetch updates, and send an
@@ -434,6 +436,9 @@ parse_cmdline () {
--not-running-from-cron)
NOTTYOK=1
;;
+ --currently-running)
+ shift; export UNAME_r="$1"
+ ;;
# Configuration file equivalents
-b)
OpenPOWER on IntegriCloud