2017 © Pedro Peláez
 

library virtman

A LibVirt wrapper for Laravel.

image

ryanvade/virtman

A LibVirt wrapper for Laravel.

  • Tuesday, January 3, 2017
  • by ryanvade
  • Repository
  • 3 Watchers
  • 2 Stars
  • 21 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

VirtMan

A Libvirt PHP wrapper library for the Laravel Framework. version 0.0.1, (*1)

Requirements

  • PHP >= 7.0
  • Libvirt PHP extension

Installation

First grab the package via composer., (*2)

composer require ryanvade/virtman

Then add the service provider to the list of providers in config/app.php., (*3)

...
        /*
         * Package Service Providers...
         */

        VirtMan\VirtManServiceProvider::class,
...

Finally publish the package to your laravel project and run the migrations., (*4)

php artisan vendor:publish
php artisan migrate

Examples

Create a Storage Object

use VirtMan\VirtMan;

$virtMan = new VirtMan();
$testInstallImage = $virtMan->createStorage("installimage.iso", "ISO", -1);
$testStorage = $virtMan->createStorage("TestStorage", "qcow2", 20480);

Create a Network Object


$network = $virtMan->createNetwork("00:11:22:33:44:55", "machine_network", "e1000");

Create a Virtual Machine

$machine = $virtMan->createMachine("TestMachine", "Linux", 2048, 1, "x86_64", [
  $testInstallImage,
  $testStorage],
  $network);

TODO

  • [ ] Create Virtual Machines
  • [x] Create Storage Images
  • [ ] Create Storage Pools
  • [x] Create Networks
  • [ ] Create Machine Groups
  • [ ] Delete Virtual Machines
  • [ ] Delete Storage Images
  • [ ] Delete Storage Pools
  • [ ] Delete Networks
  • [ ] Delete Machine Groups
  • [ ] List Machines
  • [ ] Change Machine Settings
  • [ ] Change Machine Networks
  • [ ] Add a Machine to a Network
  • [ ] Clone a Machine
  • [ ] Add Storage to a Storage Pool
  • [ ] Manage Install Images

The Versions

03/01 2017

dev-master

9999999-dev

A LibVirt wrapper for Laravel.

  Sources   Download

MIT

The Requires

 

by Ryan Owens