Package: bsdploy
BSDploy – FreeBSD jail provisioningBSDploy is a comprehensive tool to remotelyprovision,configureandmaintainFreeBSDjail hosts and jails.Its main design goal is to lower the barrier torepeatable jail setups.Instead of performing updates on production hosts you are encouraged to update thedescriptionof your setup, test it against an identically configured staging scenario until it works as expected and then apply the updated configuration to production with confidence.Main Featuresprovisioncomplete jail hosts from scratchdescribeone or more jail hosts and their jails in a canonical configurationdeclarative configuration– applyAnsibleplaybooks to hosts and jailsimperative maintenance– runFabricscripts against hosts and jailsconfigureZFS pools and filesystemswithwhole-disk-encryptionmodular provisioningwith plugins forVirtualBoxandAmazon EC2and an architecture to support more.How it worksBSDploy takes the shape of a commandline tool by the name ofploywhich is installed on a so-calledcontrol host(typically your laptop or desktop machine) with which you then control one or moretarget hosts. The only two things installed on target hosts by BSDploy are Python andezjail– everything else stays on the control host.Example SessionHere’s what an abbreviated bootstrapping session of a simple website inside a jail on an Amazon EC2 instance could look like:# ploy start ec-instance
[...]
# ploy configure jailhost
[...]
# ploy start webserver
[...]
# ploy configure webserver
[...]
# ploy do webserver upload_websiteBest of both worldsCombining a declarative approach for setting up the initial state of a system with an imperative approach for providing maintenance operations on that state has significant advantages:Since the imperative scripts have the luxury of running against a well-defined context, you can keep them short and concise without worrying about all those edge cases.And since the playbooks needn’t concern themselves with performing updates or other tasks you don’t have to litter them with awkward states such asrestartedorupdatedor – even worse – with non-states such asshellcommands.Under the hoodBSDploy’s scope is quite ambitious, so naturally it does not attempt to do all of the work on its own. In fact, BSDPloy is just a fairly thin, slightly opinionated wrapper around existing excellent tools.In addition to the above mentioned Ansible and Fabric, it usesezjailon the host to manage the jails and on the client numerous members of theployground familyfor pretty much everything else.Full documentationThe full documentation ishosted at RTD.Changes3.0.0 - 2022-08-17[feature] support Python 3.10.3.0.0b4 - 2020-09-08[feature] supportbootstrap-passwordoption.[feature] allow override ofdestroygeomviabootstrap-destroygeom.[feature] allow override of packages installed during bootstrap viabootstrap-packages.[fix] correct path to devfs device in mfsbsd boostrap script.3.0.0b3 - 2019-06-09[feature] Python 3.x support with Ansible >= 2.4.x.[feature] the sysrc module supportsdstoption to use another file then the default/etc/rc.conf.[change] renamedbootstrap-host-keystobootstrap-ssh-host-keys.[change] reintroducebootstrap-ssh-fingerprintsto allow overriding ofssh-fingerprintsfor bootstrapping.3.0.0b2 - 2018-02-11[change] ask before automatically generating missing ssh host keys during bootstrap.[change] the default location forbootstrap-fileschanged from[playbooks-directory]/bootstrap-filesto[playbooks-directory]/[instance-uid]/bootstrap-files.[change] renamedfirstboot-updatetobootstrap-firstboot-updateto match the other variables.3.0.0b1 - 2018-02-07[change] switch to use ploy 2.0.0 and Ansible 2.4.x.[feature] thefabfileoption is set if[instance-name]/fabfile.pyexists when the more specific[master-name]-[instance-name]/fabfile.pydoesn’t exist.[fix]: honour theboottrap-packagessetting for mfsbsd.2.3.0 - 2017-11-13[fix] fix pf round-robin lockups. thanks to @igalic for reporting and fixing this issue[feature] add ed25519 support in bootstrap needed for paramiko>=2. you should check whether you havessh_host_ed25519_key*files on your host which you might want to copy to your bootstrap files directory alongside the otherssh_host_*_key*files[change] removed local rsa1 host key generation2.2.0 - 2016-11-08[feature] add fabric helpers to keep pkg up-to-date on the host, inside jails and for the bsdploy flavour[feature] add support for bootstrapping on Digital Ocean by settingbootstraptodigitaloceanin theez-masterdefinition[fix] allow setting a non-default zfs root for ezjail by settingjails_zfs_rootin theez-masterdefinition2.1.0 - 2015-07-26[feature] enable jail_parallel_start in rc.conf of jail host[fix] import existing zpool inzpoolansible module if the name matches[fix] try to attach geli device first inzpoolansible module, in case it already exists, only if that fails create it from scratch[fix] properly handle multiple geli encrypted devices inzpoolansible module[fix] also honor theploy_jail_host_pkg_repositoryvariable during bootstrapping (not just jailhost configuration)[feature] files copied during bootstrap can be encrypted using theploy vaultcommands. This is useful for the private ssh host keys inbootstrap-files.[fix] fixed setting of virtualbox defaults, so they can be properly overwritten[feature] added new variables: ploy_jail_host_cloned_interfaces/ploy_jail_host_default_jail_interface to give more flexiblity around network interface setup[change] dropped support for Ansible versions < 1.8 (supports 1.8.x and 1.9.x now)[fix] honour proxy setting while installing ezjail itself, not just during ezjail’s install run (thanks mzs114!https://github.com/ployground/bsdploy/pull/81)2.0.0 - 2015-03-05[feature] add support for http proxies[change] deactivate pkg’sauto updatefeature by default[feature] add support forfirstboot-freebsd-update(disabled by default)[change] [BACKWARDS INCOMPATIBLE] switched from ipfilter to pf - you must convert any existingipnat_rulesto the newpf_nat_rules.[feature] provide defaults for VirtualBox instances (less boilerplate)[fix] set full /etc/ntp.conf instead of trying to fiddle with an existing one.[feature] Support configuration as non-root user (seehttps://github.com/ployground/bsdploy/issues/62)[change] switched to semantic versioning (seehttp://semver.org)1.3 - 2014-11-28[deprecation] rsync_project is not working in all cases, print a warning[feature] added rsync helper, which is a tiny wrapper around the rsync command[fix] change format of /usr/local/etc/pkg/repos/FreeBSD.conf so the package
repository is properly recognized[change] use quarterly package repository everywhere1.2 - 2014-10-26[feature] provide default and by-convention assignment of fabfiles[doc] document provisioning of EC2 instances[fix] fix string escapes for geli setup in rc.conf[feature] make sshd listen address configurable[fix] fix permission of periodic scripts in zfs_auto_snapshot role[doc] describe how to use a http proxy for mfsBSD1.1.1 - 2014-09-25increase memory for virtual machines in documentation from 512MB to 1024MBfix escaping for jail settings in rc.conf preventing jails from starting1.1.0 - 2014-08-13use FreeBSD 10.0 as default for bootstrapping and documentationalways encode result of templates as utf-8fix compatibility with ansible 1.71.0.0 - 2014-07-20added bsdploy.fabutils with a wrapper for rsync_projectautomatically set env.shell for fabric scripts.generate ssh host keys locally during bootstrap if possible.setfingerprintoption for ezjail master automatically if a ssh host key exists locally.1.0b4 - 2014-07-08remove customployandploy-sshconsole scripts.1.0b3 - 2014-07-07makeploy_virtualboxan optional dependency1.0b2 - 2014-07-07migrate frommr.awsome*dependencies toploy*various bugfixesadded tests1.0b1 - 2014-06-17Initial public release