Giter Club home page Giter Club logo

Comments (3)

trapgate avatar trapgate commented on July 23, 2024

I think you want to look at DomainMigrate3, where you can provide a connection to the destination host as part of the call. You can also look at the virsh sources to see how it builds its connection objects when certs are used.

from go-libvirt.

hunkeelin avatar hunkeelin commented on July 23, 2024

Yes you can provide the connection via the following:

dconnuri := []string{"qemu+tls://foo/system"}

if _, err := l.DomainMigratePerform3Params(dom, dconnuri,

	[]TypedParam{}, []byte{}, flags); err != nil {

	t.Fatalf("unexpected live migration error: %v", err)

}

I can specify the string to be qemu+tls. However, I am having a disconnection on where to put the key,cert and ca information for mtls to work. in virsh, it will read the the keys,cert and ca.pem in the locations i specifiy on OP automatically.

Mtls require the client to provide it's own set of key,cert. (The ca on the client side is to trust the cert from the server hosting libvirtd via tls.)

from go-libvirt.

trapgate avatar trapgate commented on July 23, 2024

The code that reads the cert and key from disk is part of virsh, not libvirt's rpc interface. It would be possible to add such a thing to go-libvirt as a convenience function, but it doesn't exist today. I'm going to close this issue, but if you want to file a PR for this work, you can reopen it for discussion.

from go-libvirt.

Related Issues (20)

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.