Skip to content
项目

terraform-lxd/terraform-provider-lxd

在 GitHub 查看

关于

LXD Resource provider for Terraform

系统与基础设施

这些数字如何统计

实测星标增长

24小时
-1
7天
-1
15天
-1
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

terraform-provider-lxd

LXD Resource provider for Terraform

Prerequisites

Installation

This provider is published in the Terraform Registry.

Follow the official instructions for declaring providers in your Terraform configuration here.

Quick Example

Add the following to your Terraform configuration:

terraform {
  required_providers {
    lxd = {
      source = "terraform-lxd/lxd"
    }
  }
}

Development

Setup

  1. Follow these instructions to setup a Golang development environment.
  2. Checkout the repository git clone ...
  3. Compile from sources to a development binary:
cd terraform-provider-lxd
go build -v
  1. Configure Terraform (~/.terraformrc) to use the development binary provider:
$ cat ~/.terraformrc
provider_installation {
  # Use local git clone of LXD provider
  dev_overrides {
    "terraform-lxd/lxd" = "/home/<REPLACE_ME>/git/terraform-provider-lxd"
  }

  # For all other providers, install them directly from their origin provider
  # registries as normal. If you omit this, Terraform will _only_ use
  # the dev_overrides block, and so no other providers will be available.
  direct {}
}

Testing

There are two test suites, unit and acceptance. By default the acceptance tests are not run as they require a functional LXD environment.

Unit tests
make
Acceptance tests
make testacc
# or run an individual test
TESTARGS="-run TestAccImage_basicVM" make testacc
# increase test verbosity. options are trace, debug, info, warn, or error (default)
TF_LOG=info make testacc

Documentation

Full documentation can be found in the docs directory.

探索相关项目

加载中…