terraform-provider-kubevirt

command module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 22, 2023 License: Apache-2.0 Imports: 2 Imported by: 1

README

Terraform Provider

Requirements

  • Terraform 0.12.x
  • Go 1.14 (to build the provider plugin)

Building The Provider

  1. Clone repository

  2. Change directory to repository root folder

  3. Build the project by running make build

$ make build

Using the provider

In order to use it in your computer, run install command inside the repository:

$ make install

You can find examples how to use the provider in _example directory

Contributing to the Provider

Code structure
  • All code located under kubevirt directory
  • Backend kubevirt client wrapper located in client
  • All terraform schema definitions located under schema directory
  • Terraform resource is defined (operations and schema) in kubevirt/resource_*.go for example: virtualmachine resource defined here
  • The main file, which define the provider's flags and structures is provider
Development Environment

If you wish to work on the provider, you'll first need Go installed on your machine (version 1.14+ is required).

To compile the provider, run make build. This will build the provider and put the provider binary in the repository root directory.

$ make build

In order to test the provider, you can simply run make test.

$ make test

In order to run terraform on your computer with terraform-provider-kubevirt, run make install

$ make install

That would build the binary and copy it to $(HOME)/.terraform.d/plugins/$(GOOS)_$(GOARCH)

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
ci-tests
terraform/lineprinter
Package lineprinter wraps a Print implementation to provide an io.WriteCloser.
Package lineprinter wraps a Print implementation to provide an io.WriteCloser.
client/mock
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL