Skip to content

Commit

Permalink
Add the "vbmc" utility
Browse files Browse the repository at this point in the history
This patch is refactoring the code and adding the vbmc utility.
  • Loading branch information
umago committed Feb 12, 2016
1 parent d985f52 commit f6e7153
Show file tree
Hide file tree
Showing 11 changed files with 555 additions and 190 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
*.py[co]
.*.swp
*~
build
dist
*egg-info
*egg
33 changes: 33 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
Virtual BMC
===========

A virtual BMC for controlling virtual machines using IPMI commands.

Installation
------------

```bash
pip install virtualbmc
```

Usage
-----

![alt text](images/demo.gif "Virtual BMC demo")

Other supported commands
------------------------

```bash
# Power the virtual machine on or off
ipmitool -I lanplus -U admin -P password -H 127.0.0.1 power on|off

# Check the power status
ipmitool -I lanplus -U admin -P password -H 127.0.0.1 power status

# Set the boot device to network, hd or cdrom
ipmitool -I lanplus -U admin -P password -H 127.0.0.1 chassis bootdev pxe|disk|cdrom

# Get the current boot device
ipmitool -I lanplus -U admin -P password -H 127.0.0.1 chassis bootparam get 5
```
27 changes: 0 additions & 27 deletions README.rst

This file was deleted.

Binary file added images/demo.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
40 changes: 40 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# 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
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# 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.

from setuptools import setup

setup(name='virtualbmc',
version='0.0.1',
description=('Create virtual BMCs for controlling virtual instances '
'via IPMI'),
url='http://github.com/umago/virtualbmc',
author='Lucas Alvares Gomes',
author_email='[email protected]',
license='Apache License 2.0',
packages=['virtualbmc', 'virtualbmc.cmd'],
install_requires=['six',
'python-daemon',
'prettytable',
'libvirt-python',
'pyghmi>=0.9.8'],
entry_points = {
'console_scripts': [
'vbmc = virtualbmc.cmd.vbmc:main',
],
},
classifiers=[
'Development Status :: 3 - Alpha',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License',
'Programming Language :: Python',
],
)
163 changes: 0 additions & 163 deletions virtualbmc.py

This file was deleted.

20 changes: 20 additions & 0 deletions virtualbmc/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Copyright 2016 Red Hat, Inc.
# All Rights Reserved.
#
# 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
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# 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.

__all__ = ['exception', 'VirtualBMC', 'VirtualBMCManager']

import exception
from virtualbmc import VirtualBMC
from virtualbmc import VirtualBMCManager
Empty file added virtualbmc/cmd/__init__.py
Empty file.
Loading

0 comments on commit f6e7153

Please sign in to comment.