Git Product home page Git Product logo

packer-vagrant-centos's Introduction

CentOS Linux for Vagrant

Packer templates to build a small CentOS Linux box designed for use in Vagrant.

What is CentOS?

The CentOS Project is a community-driven free software effort focused on delivering a robust open source ecosystem. For users, we offer a consistent manageable platform that suits a wide variety of deployments. For open source communities, we offer a solid, predictable base to build upon, along with extensive resources to build, test, release, and maintain their code.

from centos.org

Synopsis

This is a set of templates designed for use with Packer to create Vagrant boxes with CentOS installed.

All non-required packages were removed to create this small box. When using this box you may have to install some of the packages that usually are installed on a regular CentOS Linux Vagrant box.

Getting Started

There are a couple of things needed for the templates to work.

Prerequisites

Packer, Vagrant, Virtualbox, and VMWare need to be installed on your local computer.

Packer

Packer installation instructions can be found here.

Vagrant

Vagrant installation instructions can be found here.

Virtualbox

Virtualbox installation instructions can be found here.

As of CentOS Stream release 8 Virtualbox 6.1.27 or higher is required.

VMware

VMware installation instructions will depend on the VMware product that you want. Go to the desired product page at VMware and check for the appropriate documentation.

Vagrant support for the VMWare hypervisor is provided by the Vagrant VMWare Utility that can be downloaded from here. and by the Vagrant VMware provider that can be installed by running the following command on a terminal:

vagrant plugin install vagrant-vmware-desktop

Usage

To create a virtual machine using this box create a folder and run the following command inside that folder:

vagrant init fscm/centos

To start that virtual machine run:

vagrant up

This box is available for multiple providers. See the table below to find out how to run a specific provider.

provider command
virtualbox vagrant up --provider=virtualbox
vmware vagrant up --provider=vmware_desktop

Build

In order to create a CentOS Linux Vagrant box using this Packer recipe you need to run the following packer command on the root of this project:

packer build [-var 'option=value'] <VARIANT>
  • <VARIANT> - [required] The variant that is being build (stream8).

Options:

  • disk_size_mb - The disk size in megabytes (default value:8192).
  • debug - Enable debug (default value:false).
  • domain - The network domain (default value:"vagrant.local").
  • hostname - The system hostname (default value:"centos").
  • os_version - The OS version (default value:"8").
  • password - The password for the user (default value:"stream").
  • username - The username for the user (default value:"stream").

The recipe will, by default, build a box for every supported provider. To build only for the desired one(s) use the -only packer option.

List of supported providers:

provider option
virtualbox -only=virtualbox-iso.virtualbox
vmware -only=vmware-iso.vmware

More than one provider can be specified by separating the names with commas (e.g.: -only=virtualbox-iso.virtualbox,vmware-iso.vmware).

A build example:

packer build -only=vmware-iso.vmware -var 'debug=true' stream8

Contributing

  1. Fork it!
  2. Create your feature branch: git checkout -b my-new-feature
  3. Commit your changes: git commit -am 'Add some feature'
  4. Push to the branch: git push origin my-new-feature
  5. Submit a pull request

Please read the CONTRIBUTING.md file for more details on how to contribute to this project.

Versioning

This project uses SemVer for versioning. For the versions available, see the tags on this repository.

Authors

  • Frederico Martins - fscm

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE file for details

packer-vagrant-centos's People

Contributors

fscm avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.