Code Monkey home page Code Monkey logo

python-oca's People

Contributors

lukaszo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

python-oca's Issues

List of templates

Hi Lukas,

I am trying to get a list of templates, in the same way I can get a list of virtual machines. But it seems that the vmtemplatepool.info not yet is implemented. Can you maybe have a look at that?

Thanks!

Mattias

Instantiate a VM template

Hi,
How can I instantiate and deploy a VM from a VM template ?
I was able to get the VM templates with the command: vmtemplatepool.info()

Thank you

Obtaining the IP address of an vm

Hello,

How can I get the IP address of a virtual machine?

It is not listed as one of the attributes:
list(vmpool)[-1].xml.getchildren()

Out[15]: 
[<Element ID at 305d248>,
 <Element UID at 305d2d8>,
 <Element USERNAME at 305d368>,
 <Element NAME at 305d3f8>,
 <Element LAST_POLL at 305d488>,
 <Element STATE at 305d518>,
 <Element LCM_STATE at 305d5a8>,
 <Element STIME at 305d638>,
 <Element ETIME at 305d6c8>,
 <Element DEPLOY_ID at 305d758>,
 <Element MEMORY at 305d7e8>,
 <Element CPU at 305d878>,
 <Element NET_TX at 305d908>,
 <Element NET_RX at 305d998>,
 <Element LAST_SEQ at 305da28>,
 <Element HISTORY at 305dab8>]```

But I noticed that is provided as output of the one.vm.info function:
<IP><![CDATA[10.0.72.12]]></IP>

But all the fields that contain a CDATA value are note listed in the vmpool object.

Any ideas how to get the ip address into the vm object?

Thanks!

oca.VirtualMachinePool.info() not working

Hello lukaszo,

I am testing out your python wrapper to OpenNebula. If I try to get the results of one.vmpool.info I retrieve an error:
vmpool = oca.VirtualMachinePool(client)
vmpool.info()
xmlrpclib.Fault: Fault 501: 'Not enough parameters'

Looking into that into more detail, I think you also need to pass a client_id:
Doing this results in a feedback from the server:
client.call("vmpool.info", -1)
VM_POOL ... VM_POOL

According to the Ruby wrapper (http://www.opennebula.org/documentation:archives:rel2.0:ruby) there is a need to pass a second argument to VirtualMachinePool: vm_pool = VirtualMachinePool.new(client, -1)

Can you please verify this?

Thanks!

Mattias

Examples

Hey there,

would it be possible for you to add 2-3 more examples?

A little structure like
-> get list of hosts
-> get list of vms
-> associate them

but in single steps with comments would be great to help non-coders like me move over the first silly stuff.
I looked at the pydoc doc for init() and it was already too unclear for me. :/
What is "client", etc.

I then got a lot of exceptions just trying to test the example and both things combined, had to give up :(

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.