by chef

chef /bento

Packer templates for building minimal Vagrant baseboxes for multiple platforms

3.5K Stars 933 Forks Last release: about 2 years ago (v201808.24.0) Apache License 2.0 1.9K Commits 25 Releases

Available items

No Items, yet!

The developer of this repository has not created any items for sale yet. Need a bug fixed? Help with integration? A different license? Create a request here:


Build status

Bento is a project that encapsulates Packer templates for building Vagrant base boxes. A subset of templates are built and published to the bento org on Vagrant Cloud. These published boxes serve as the default boxes for kitchen-vagrant.

Using Public Boxes

Adding a bento box to Vagrant

$ vagrant box add bento/ubuntu-18.04

Using a bento box in a Vagrantfile

Vagrant.configure("2") do |config| = "bento/ubuntu-18.04"

Building Boxes


*NOTE: support for these providers is considered experimental and corresponding Vagrant Cloud images may or may not exist.


To build an Ubuntu 18.04 box for only the VirtualBox provider

$ cd ubuntu
$ packer build -only=virtualbox-iso ubuntu-18.04-amd64.json

To build Debian 10.5 32bit boxes for all possible providers (simultaneously)

$ cd debian
$ packer build debian-10.5-i386.json

To build CentOS 7.7 boxes for all providers except VMware and Parallels

$ cd centos
$ packer build -except=parallels-iso,vmware-iso centos-7.7-x86_64.json

To use an alternate mirror

$ cd fedora
$ packer build -var 'mirror=' fedora-31-x86_64.json

To build a Windows 10 Enterprise Gen 2 box for the Hyper-V provider

$ cd windows
$ packer build windows-10gen2.json

If the build is successful, your box files will be in the

directory at the root of the repository.

*NOTE: boxbasename can be overridden like other Packer vars with `-var 'boxbasename=ubuntu-18.04'`

KVM/qemu support for Windows

You must download the iso image with the Windows drivers for paravirtualized KVM/qemu hardware. You can do this from the command line:

wget -nv -nc -O virtio-win.iso

You can use the following sample command to build a KVM/qemu Windows box:

packer build --only=qemu --var virtio_win_iso=~/virtio-win.iso windows-2019.json

Proprietary Templates

Templates for operating systems only available via license or subscription are also available in the repository, these include but are not limited to: macOS, Red Hat Enterprise Linux, and SUSE Linux Enterprise. As the ISOs are not publicly available the URL values will need to be overridden as appropriate. We rely on the efforts of those with access to licensed versions of the operating systems to keep these up-to-date.


Most of the providers expect unrestricted access to networking in order to build as expected. We can't enumerate all possible firewall configurations but include some snippets below that might be useful to users.


$VS = "Standardswitch"
$IF_ALIAS = (Get-NetAdapter -Name "vEthernet ($VS)").ifAlias
New-NetFirewallRule -Displayname "Allow incomming from $VS" -Direction Inbound -InterfaceAlias $IF_ALIAS -Action Allow

Hyper-V Generation 2 VM's

Hyper-V Gen 2 VMs do not support floppy drives. If you previously provided resources using a floppy drive, you must add those files to your Gen 2 iso images, in particular:

  • autounattend.xml
    : The Gen 2
    file supports EFI partitions. Update the
    with the correct Windows version for your systems and ensure that the partitions are correct for your situation. You also need to manage the driver disk that holds the hyper-v guest services drivers and adjust the
    file as appropriate.
  • base_setup.ps1

macOS / OSX

See this wiki page

Bugs and Issues

Please use GitHub issues to report bugs, features, or other problems.

Related projects


License & Authors

These basebox templates were converted from veewee definitions originally based on work done by Tim Dysinger to make "Don't Repeat Yourself" (DRY) modular baseboxes. Thanks Tim!

macOS templates were adopted wholesale from Fletcher Nichol's packer templates.

Copyright 2012-2019, Chef Software, Inc. ()
Copyright 2011-2012, Tim Dysinger ()

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.