Introducing Dogrant: A Streamlined Vagrant Configuration CLI

Dec 16, 2024 by Zacharia Mansouri | 318 views

Virtualization Docker Python

https://cylab.be/blog/383/introducing-dogrant-a-streamlined-vagrant-configuration-cli

Dogrant is a Python-powered command-line interface (CLI) designed to streamline the management of Vagrant environments and configurations, with seamless integration for Docker Compose. Packed with features for managing memory allocation, CPU usage, synced folders, forwarded ports, and more, Dogrant offers developers an efficient solution for creating and managing VMs tailored to run Docker projects.

dot_art_image_with_spacing.png

Download

Dogrant is available here among the different tools developed by cylab.be.

Why Dogrant?

Deploying VMs with Docker applications can be a complex and time-consuming process. Dogrant simplifies this challenge by providing an intuitive CLI based on Typer for defining, managing, and generating VMs tailored to your needs. Whether you’re provisioning development environments or deploying services, Dogrant ensures a seamless and efficient workflow.

Features at a Glance

  • Define and manage Vagrant configurations with ease.
  • Allocate resources like memory and CPUs effortlessly.
  • Deploy services using Docker Compose.
  • Forward ports for seamless networking.
  • Export VMs as .ova files with SSH access included.

Key Commands

  • Define the configuration of your Vagrant environment with this command.
python3 app.py generate config
  • Generate and export a Vagrant VM with Docker Compose services deployed. The output includes an .ova file and an SSH private_key for secure access.
python3 app.py generate vm
  • Remove the Vagrantfile to reset your configuration.
python3 app.py clean config
  • Clean up the exported VM files from the generated folder.
python3 app.py clean vm
  • Access the deployed VM:
ssh -i generated/private_key vagrant@<host-ip>

Conclusion

Dogrant brings together the power of Docker and Vagrant, offering developers a seamless and efficient solution for managing virtualized environments. By combining Vagrant’s robust VM management with Docker’s containerization capabilities, Dogrant automates configuration and VM generation tasks, reducing setup time and enhancing productivity.

This blog post is licensed under CC BY-SA 4.0

This website uses cookies. More information about the use of cookies is available in the cookies policy.
Accept