Provider specific options goes under cmd/cloud-api-adaptor
- The code goes under
pkg/adaptor/hypervisor/<provider>
- Use BUILD TAGs to build the provider (eg // +build libvirt).
ℹ️ Note that there will be separate binaries for each provider.
Add provider entry point to the registry. The registry.newServer
method is the entry point for the provider code.
ℹ️ Example code
The NewServer
method creates the service which is responsible for VM lifecycle operations.
Each provider implements NewServer
method.
By convention this should be in the file <provider>/server.go
Each provider implements newService
method.
By convention this should be in the file <provider>/service.go
Add required methods
- CreateVM
- StartVM
- StopVM
- Version
These methods are required by Kata and a Kata hypervisor needs to implement these methods.
Add additional files to modularize the code.
See existing providers - aws|azure|ibmcloud|libvirt
Each provider should be built and tested on CI.
Update the provider
list under the matrix
property in .github/workflows/build.yaml
.