![]() It will include things like the boxes used, networking, CPU and memory, providers used, shell scripts to run for provisioning among others. A Vagrantfile is basically a configuration file that describes an environment. To understand Vagrant, you first need to understand one of the basic building blocks – Vagrantfile. The Vagrant CLI is very easy to use and provides users a way to manage their Vagrant environment efficiently. Vagrant is a favorite among DevOps professionals as it provides a great way to great re-usable and identical test environments. ![]() ![]() Now you can use this new base box like any other Vagrant box.In this article, I will point out five commands that every Vagrant user needs to know. Please note I named output box as precise64Node as original base box is precise64 and I repackaged for Node specific uses. So for instance, if I am interested to repackage VM Node_default_1387087098 then I will run, vagrant package -base Node_default_1387087098 -output /myfolder/precise64Node.box Once you have specific name for VM which you want to repackage, you can run vagrant package -base SPECIFIC_NAME_FOR_VM -output /yourfolder/OUTPUT_BOX_NAME.box For example following image illustrate two VM running under VirtualBox Node_default_1387087098 and Blogs_default_1386384681 If you are using VirtualBox as provider you can see a list of virtual machine with their specific machine. Also repackaging allows me to work offline as no provisioning is required.įirst step is to get id or specific name of VM from your Vagrant provider. ![]() Once install/update is finished, sometime I prefer to repackage updated virtual machine as a new base box to avoid repeating the install and update process. Then using either Puppet provisioner or apt-get I normally install/update required packages and libraries in my VM. With help of a Vagrant provider vagrant up will create a virtual machine (VM) using specified base box. Typically my Vagrant workflow starts with a official base box provided by Ubuntu. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |