From: kn Date: Mon, 8 Nov 2021 16:12:09 +0000 (+0000) Subject: Rename/move site(8) into install.site(5) X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=a3154df39cef36d62ed08609a71ada5fbc5341cf;p=openbsd Rename/move site(8) into install.site(5) These sets/scripts are not commands and there is nothing actually called "site". This is configuration, so use section five. Also rename to what actually exists. Discussed with deraadt schwarze jmc OK deraadt --- diff --git a/distrib/sets/lists/man/mi b/distrib/sets/lists/man/mi index 2fcf3a58313..ab52b74cf7e 100644 --- a/distrib/sets/lists/man/mi +++ b/distrib/sets/lists/man/mi @@ -2177,6 +2177,7 @@ ./usr/share/man/man5/ifstated.conf.5 ./usr/share/man/man5/iked.conf.5 ./usr/share/man/man5/info.5 +./usr/share/man/man5/install.site.5 ./usr/share/man/man5/installurl.5 ./usr/share/man/man5/intro.5 ./usr/share/man/man5/ipsec.conf.5 @@ -2561,7 +2562,6 @@ ./usr/share/man/man8/security.8 ./usr/share/man/man8/sendmail.8 ./usr/share/man/man8/sensorsd.8 -./usr/share/man/man8/site.8 ./usr/share/man/man8/sftp-server.8 ./usr/share/man/man8/showmount.8 ./usr/share/man/man8/shutdown.8 diff --git a/share/man/man5/Makefile b/share/man/man5/Makefile index a62844dfb0a..89d6c843a1a 100644 --- a/share/man/man5/Makefile +++ b/share/man/man5/Makefile @@ -1,10 +1,11 @@ -# $OpenBSD: Makefile,v 1.60 2021/04/10 15:26:47 gnezdo Exp $ +# $OpenBSD: Makefile,v 1.61 2021/11/08 16:12:09 kn Exp $ # $NetBSD: Makefile,v 1.14 1995/05/11 23:13:15 cgd Exp $ MAN= acct.5 ar.5 bsd.port.mk.5 bsd.port.arch.mk.5 bsd.regress.mk.5 \ changelist.5 core.5 \ defaultdomain.5 dir.5 disktab.5 elf.5 ethers.5 fbtab.5 files.conf.5 \ - fs.5 fstab.5 genassym.cf.5 group.5 hostname.if.5 hosts.5 installurl.5 \ + fs.5 fstab.5 genassym.cf.5 group.5 hostname.if.5 hosts.5 \ + install.site.8 installurl.5 \ intro.5 login.conf.5 mandoc.db.5 mixerctl.conf.5 \ mk.conf.5 moduli.5 motd.5 mygate.5 myname.5 netgroup.5 passwd.5 \ pf.conf.5 pf.os.5 port-modules.5 cabal-module.5 \ diff --git a/share/man/man5/install.site.5 b/share/man/man5/install.site.5 new file mode 100644 index 00000000000..3545bda3d68 --- /dev/null +++ b/share/man/man5/install.site.5 @@ -0,0 +1,95 @@ +.\" $OpenBSD: install.site.5,v 1.1 2021/11/08 16:12:09 kn Exp $ +.\" +.\" Copyright (c) 2021 Klemens Nanni +.\" +.\" Permission to use, copy, modify, and distribute this software for any +.\" purpose with or without fee is hereby granted, provided that the above +.\" copyright notice and this permission notice appear in all copies. +.\" +.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +.\" +.Dd $Mdocdate: November 8 2021 $ +.Dt INSTALL.SITE 5 +.Os +.Sh NAME +.Nm install.site , +.Nm upgrade.site +.Nd OpenBSD installation and upgrade customization +.Sh DESCRIPTION +The +.Ox +installer allows user-created sets and scripts to complement +and modify the files from a default install prior to rebooting. +.Pp +Like the official file sets, generic +.Pa site${ Ns Va VERSION Ns }.tgz +and +hostname-specific +.Pa site${ Ns Va VERSION Ns }-$( Ns Ic hostname Fl s Ns ).tgz +sets are +.Xr gzip 1 +compressed +.Xr tar 1 +archives rooted in +.Pa / +and untarred with the +.Fl xzphf +options. +.Pp +.Em siteXY +sets +must be included in +.Pa index.txt +in order to be fetched via +HTTP(S) and selectable in the installer. +.Pp +If they exist and are executable, +.Pa /install.site +and +.Pa /upgrade.site +are run at the end of the install and upgrade process, respectively, with +.Xr chroot 8 +based at the system's root. +.Sh FILES +.Bl -tag -width "site${VERSION}-$(hostname -s).tgz" -compact +.It Pa site${ Ns Va VERSION Ns }.tgz +Generic set. +.It Pa site${ Ns Va VERSION Ns }-$( Ns Ic hostname Fl s Ns ).tgz +Host-specific set. +.It Pa /upgrade.site +Generic post-upgrade script. +.It Pa /install.site +Generic post-install script. +.El +.Sh EXAMPLES +Create +.Em site70 +sets and update the index: +.Bd -literal -offset indent +# tar -czhf site70.tgz generic/ +# tar -czhf site70-puffy.tgz puffy/ +# ls -lT > index.txt +.Ed +.Pp +Upgrade +.Xr packages 7 +upon reboot after +.Xr sysupgrade 8 +upgraded the system: +.Bd -literal -offset indent +# cat <<- EOF >> /upgrade.site + echo 'pkg_add -Iu' >>/etc/rc.firsttime +EOF +# chmod +x /upgrade.site +# sysupgrade +.Ed +.Sh SEE ALSO +.Xr autoinstall 8 , +.Xr rc 8 , +.Xr sysupgrade 8 diff --git a/share/man/man8/Makefile b/share/man/man8/Makefile index 1d9a6d1a625..7f638af0105 100644 --- a/share/man/man8/Makefile +++ b/share/man/man8/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.103 2021/11/06 01:24:37 kn Exp $ +# $OpenBSD: Makefile,v 1.104 2021/11/08 16:12:10 kn Exp $ # $NetBSD: Makefile,v 1.13 1996/03/28 21:36:40 mark Exp $ # @(#)Makefile 8.1 (Berkeley) 6/5/93 @@ -6,7 +6,7 @@ MAN= afterboot.8 autoinstall.8 boot_config.8 bulk.8 \ crash.8 daily.8 \ diskless.8 genassym.sh.8 intro.8 netstart.8 rc.8 \ rc.conf.8 rc.d.8 rc.shutdown.8 rc.subr.8 release.8 \ - security.8 site.8 ssl.8 starttls.8 sticky.8 yp.8 + security.8 ssl.8 starttls.8 sticky.8 yp.8 SUBDIR= man8.alpha man8.amd64 man8.arm64 man8.armv7 \ man8.hppa man8.i386 man8.landisk \ diff --git a/share/man/man8/autoinstall.8 b/share/man/man8/autoinstall.8 index b21a7cef532..9fef3643898 100644 --- a/share/man/man8/autoinstall.8 +++ b/share/man/man8/autoinstall.8 @@ -1,4 +1,4 @@ -.\" $OpenBSD: autoinstall.8,v 1.24 2021/11/06 01:24:37 kn Exp $ +.\" $OpenBSD: autoinstall.8,v 1.25 2021/11/08 16:12:10 kn Exp $ .\" .\" Copyright (c) 2013 Robert Peichaer .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: November 6 2021 $ +.Dd $Mdocdate: November 8 2021 $ .Dt AUTOINSTALL 8 .Os .Sh NAME @@ -33,7 +33,7 @@ If that fails, the installer asks for the location which can either be a URL or a local path. .Pp See -.Xr site 8 +.Xr install.site 5 for how to provide custom configuration. .Pp To start unattended installation or upgrade choose '(A)utoinstall' at the @@ -239,8 +239,8 @@ host foo { .Sh SEE ALSO .Xr dhcp-options 5 , .Xr dhcpd.conf 5 , -.Xr diskless 8 , -.Xr site 8 +.Xr install.site 5 , +.Xr diskless 8 .Sh HISTORY The .Nm diff --git a/share/man/man8/site.8 b/share/man/man8/site.8 deleted file mode 100644 index 03acf0b87d9..00000000000 --- a/share/man/man8/site.8 +++ /dev/null @@ -1,96 +0,0 @@ -.\" $OpenBSD: site.8,v 1.3 2021/11/06 01:37:02 kn Exp $ -.\" -.\" Copyright (c) 2021 Klemens Nanni -.\" -.\" Permission to use, copy, modify, and distribute this software for any -.\" purpose with or without fee is hereby granted, provided that the above -.\" copyright notice and this permission notice appear in all copies. -.\" -.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -.\" -.Dd $Mdocdate: November 6 2021 $ -.Dt SITE 8 -.Os -.Sh NAME -.Nm site , -.Nm install.site , -.Nm upgrade.site -.Nd OpenBSD installation and upgrade customization -.Sh DESCRIPTION -The -.Ox -installer allows user-created sets and scripts to complement -and modify the files from a default install prior to rebooting. -.Pp -Like the official file sets, generic -.Pa site${ Ns Va VERSION Ns }.tgz -and -hostname-specific -.Pa site${ Ns Va VERSION Ns }-$( Ns Ic hostname Fl s Ns ).tgz -sets are -.Xr gzip 1 -compressed -.Xr tar 1 -archives rooted in -.Pa / -and untarred with the -.Fl xzphf -options. -.Pp -.Nm -sets -must be included in -.Pa index.txt -in order to be fetched via -HTTP(S) and selectable in the installer. -.Pp -If they exist and are executable, -.Pa /install.site -and -.Pa /upgrade.site -are run at the end of the install and upgrade process, respectively, with -.Xr chroot 8 -based at the system's root. -.Sh FILES -.Bl -tag -width "site${VERSION}-$(hostname -s).tgz" -compact -.It Pa site${ Ns Va VERSION Ns }.tgz -Generic set. -.It Pa site${ Ns Va VERSION Ns }-$( Ns Ic hostname Fl s Ns ).tgz -Host-specific set. -.It Pa /upgrade.site -Generic post-upgrade script. -.It Pa /install.site -Generic post-install script. -.El -.Sh EXAMPLES -Create -.Nm -sets and update the index: -.Bd -literal -offset indent -# tar -czhf site70.tgz generic/ -# tar -czhf site70-puffy.tgz puffy/ -# ls -lT > index.txt -.Ed -.Pp -Upgrade -.Xr packages 7 -upon reboot after -.Xr sysupgrade 8 -upgraded the system: -.Bd -literal -offset indent -# cat <<- EOF >> /upgrade.site - echo 'pkg_add -Iu' >>/etc/rc.firsttime -EOF -# chmod +x /upgrade.site -# sysupgrade -.Ed -.Sh SEE ALSO -.Xr autoinstall 8 , -.Xr rc 8 , -.Xr sysupgrade 8 diff --git a/usr.sbin/sysupgrade/sysupgrade.8 b/usr.sbin/sysupgrade/sysupgrade.8 index 7f37c931144..444c74aa64b 100644 --- a/usr.sbin/sysupgrade/sysupgrade.8 +++ b/usr.sbin/sysupgrade/sysupgrade.8 @@ -1,4 +1,4 @@ -.\" $OpenBSD: sysupgrade.8,v 1.11 2021/11/06 01:24:37 kn Exp $ +.\" $OpenBSD: sysupgrade.8,v 1.12 2021/11/08 16:12:10 kn Exp $ .\" .\" Copyright (c) 2019 Florian Obser .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: November 6 2021 $ +.Dd $Mdocdate: November 8 2021 $ .Dt SYSUPGRADE 8 .Os .Sh NAME @@ -69,7 +69,7 @@ This is the default if the system is currently running a snapshot. .El .Pp See -.Xr site 8 +.Xr upgrade.site 5 for how to customize the upgrade process. .Sh FILES .Bl -tag -width "/auto_upgrade.conf" -compact @@ -86,9 +86,9 @@ Directory the upgrade is downloaded to. .Sh SEE ALSO .Xr signify 1 , .Xr installurl 5 , +.Xr upgrade.site 5 , .Xr autoinstall 8 , -.Xr release 8 , -.Xr site 8 +.Xr release 8 .Sh HISTORY .Nm first appeared in