1.\" $OpenBSD: install.site.5,v 1.1 2021/11/08 16:12:09 kn Exp $ 2.\" 3.\" Copyright (c) 2021 Klemens Nanni <kn@openbsd.org> 4.\" 5.\" Permission to use, copy, modify, and distribute this software for any 6.\" purpose with or without fee is hereby granted, provided that the above 7.\" copyright notice and this permission notice appear in all copies. 8.\" 9.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 10.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 12.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 15.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16.\" 17.Dd $Mdocdate: November 8 2021 $ 18.Dt INSTALL.SITE 5 19.Os 20.Sh NAME 21.Nm install.site , 22.Nm upgrade.site 23.Nd OpenBSD installation and upgrade customization 24.Sh DESCRIPTION 25The 26.Ox 27installer allows user-created sets and scripts to complement 28and modify the files from a default install prior to rebooting. 29.Pp 30Like the official file sets, generic 31.Pa site${ Ns Va VERSION Ns }.tgz 32and 33hostname-specific 34.Pa site${ Ns Va VERSION Ns }-$( Ns Ic hostname Fl s Ns ).tgz 35sets are 36.Xr gzip 1 37compressed 38.Xr tar 1 39archives rooted in 40.Pa / 41and untarred with the 42.Fl xzphf 43options. 44.Pp 45.Em siteXY 46sets 47must be included in 48.Pa index.txt 49in order to be fetched via 50HTTP(S) and selectable in the installer. 51.Pp 52If they exist and are executable, 53.Pa /install.site 54and 55.Pa /upgrade.site 56are run at the end of the install and upgrade process, respectively, with 57.Xr chroot 8 58based at the system's root. 59.Sh FILES 60.Bl -tag -width "site${VERSION}-$(hostname -s).tgz" -compact 61.It Pa site${ Ns Va VERSION Ns }.tgz 62Generic set. 63.It Pa site${ Ns Va VERSION Ns }-$( Ns Ic hostname Fl s Ns ).tgz 64Host-specific set. 65.It Pa /upgrade.site 66Generic post-upgrade script. 67.It Pa /install.site 68Generic post-install script. 69.El 70.Sh EXAMPLES 71Create 72.Em site70 73sets and update the index: 74.Bd -literal -offset indent 75# tar -czhf site70.tgz generic/ 76# tar -czhf site70-puffy.tgz puffy/ 77# ls -lT > index.txt 78.Ed 79.Pp 80Upgrade 81.Xr packages 7 82upon reboot after 83.Xr sysupgrade 8 84upgraded the system: 85.Bd -literal -offset indent 86# cat <<- EOF >> /upgrade.site 87 echo 'pkg_add -Iu' >>/etc/rc.firsttime 88EOF 89# chmod +x /upgrade.site 90# sysupgrade 91.Ed 92.Sh SEE ALSO 93.Xr autoinstall 8 , 94.Xr rc 8 , 95.Xr sysupgrade 8 96