rc.d: Fix eval bug in routed script The 'eval' command would fail when 'router_flags' had space or other special character in it. Fix it. Meanwhile, update the 'eval' command in route6d script to use the same format for consistency, although it was correct.
rc.d: Clean up and tweak dependencies - Don't use real entries in the dummy scripts; instead, use the dummy entries in the real rc scripts. This makes the dummy entries clean. - Use dummy entries instead of one/multiple real entries (such as 'root') wherever appropriate. - Use 'REQUIRE' instead of 'BEFORE' wherever appropriate, which makes it clearer to understand. - Simplify and clean up various dependencies; remove unnecessary requires. - Tweak dependencies of some scripts to make the startup order more sensible. For example, make 'hostname' and 'ip6addrctl' run a bit later, after 'FILESYSTEMS' but before 'NETWORKING'. Referred to FreeBSD for some changes.
rc.d: Various style and whitespace cleanups No functional changes.
rc.d: Add FILESYSTEMS dummy dependency This dummy dependency ensures that root and other critical local file systems are mounted. One of the intentions to add this dummy dependency is to fix the warnings caused by some ports' rc script wrongly dependent on this script. Update the rc.8 man page; meanwhile, tweak the description of other dummy dependencies a bit. Updating existing rc scripts to make use of FILESYSTEMS is coming in another commit. Obtained-from: FreeBSD
wg: Write rc(8) script to easily manage wg(4) interfaces This "wg" rc(8) script is somewhat similar to the "wg-quick" tool on Linux/FreeBSD. It can be used to quickly start/stop the wg(4) interfaces according to the wg.conf(5) configuration files in the "/etc/wireguard" directory. The syntax of wg.conf(5) configuration file is very similar to that of "wg-quick" but with necessary changes and minor additions. See wg.conf(5) for details. On the one hand, the new "wg_enable" and "wg_interfaces" variables in "/etc/rc.conf" can be used to auto-configure the wg(4) interfaces during the system startup. See rc.conf(5) for more details. On the other hand, this "wg" script can be manually called from the command-line to start/stop the wg(4) interfaces. Thanks to swildner for reviewing the man page.
Add integrated dports build feature to build-all and install-all targets When WITH_DPORTS=YES is used build-all and install-all, these targets will also build the base set of ports and all of their dependencies using configuration data and the "dragonfly/base" dport found in "/usr/src/dports.base". This feature is intended to be used by the nrelease build in an upcoming commit, and may also be used manually. The /usr/dports tree must exist and contains the dports repo to use as the basis of the dports build. It will be null-mounted in the chroot and the "/usr/src/dports.base/dragonfly" directory will be null-mounted under it to provide the "dragonfly/base" meta-port. The DPORTSBASE make variable may be used to override the location of the main dports repo. The build-all and install-all targets use a sophisticated chrooted environment to do a completely clean dports build with dsynth. It It will actually "make installworld" plus a clean "make distribution" inside the chroot environment to create the environment, and the host system's /etc/resolv.conf will be copied in. build-all - Augmented when used WITH_DPORTS=YES install-all - Augmented when used WITH_DPORTS=YES buildportschroot - Build a fresh chroot environment for dsynth mountports - Do all null mounts and cp's needed for the env buildports - Run dsynth build dragonfly/base in the env installports - Install the built ports on the host system (see note) umountports - Remove the null mounts WITH_DPORTS=YES - executes buildportschroot, mountports, buildports, and umountports when run from build-all. executes mountports, installports, umountports when run from install-all. DPORTSBASE=path - Defaults to /usr/dports, may be used to override the location where the main dports tree can be found. NOTE: Installports may require interactivity as the base system might already have installed ports. Generally speaking it is best to not revert any ports you might already have installed, so feel free to tell it not to install anything. * Added various make targets and augmented build-all and install-all * /usr/local/sbin added and the stale /usr/pkg/bin removed from _HOSTPATH. * Add /usr/src/dports.base infrastructure. It contains the dsynth.ini and pkg.conf files that will be used for the local dsynth operations. Some paths are replaced with SED when copied to the chroot. The dsynth.ini is relative to the chroot. It also contains the dragonfly/base dport which is the meta-port that dsynth will be told to build. All other dports related files and directories are null-mounted from /usr/dports. * Add /usr/distfiles.base to mtree/BSD.usr.dist. This directory is also created by the build if it does not exist since the host system might not have run a new installworld recently. This directory will be used during build-all (buildports) to store the distfiles required to build dragonfly/base, so they only need to be fetched once. * Add the "-C ConfigBase" option to dsynth to make running it from the chrooted environment easier. This overrides the /etc/dsynth directory and removes /etc/dsynth as a fallback. * dsynth conditionalizes calling syscap_set() for backwards compatibility with older host systems that might not have been upgraded to include the feature yet.
usr/Makefile: Fix SSL verification issue in pkg bootstrap * Use environment variable 'SSL_NO_VERIFY_PEER=1' to let both fetch(1) and pkg-static(8) not verify peer when there is not yet a CA store (i.e., /etc/ssl/cert.pem from port 'security/ca_root_nss'). * Only check the existence of '/etc/ssl/cert.pem' as fetch(1) only checks that by default. * The newer pkg bootstrap directly provides 'df-latest.conf', so no need to copy it from the sample file. Fix the code to take it into account. Bug: https://bugs.dragonflybsd.org/issues/3338
world - Add /etc/rc.local.d to rcorder startup and shutdown ops * System now rcorders across both /etc/rc.d and /etc/rc.local.d during startup and shutdown. * Allows the sysadmin to put control scripts in /etc/rc.local.d formatted similarly to how they are in /etc/rc.d Submitted-by: Stephen Welker <stephen.welker@nemostar.com.au>
ext2fs: Remove sys/gnu/vfs/ext2fs and make sys/vfs/ext2fs the default This commit removes the old+unstable GPL ext2 implementation, and makes the new FreeBSD based ext2 implementation (since cfe603905713d4e92a7956678970d5dff8e913f2) the default. - Remove sys/gnu/vfs. - Rename sys/vfs/ext2fs/ext2fs_freebsd.ko -> ext2fs.ko. - Modify unusual userspace program which includes kernel struct. - Bump __DragonFly_version to 600107.