terraform-provider-sdm

command module
v1.0.39 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2022 License: MPL-2.0 Imports: 2 Imported by: 0

README

Terraform Provider for strongDM

The strongDM provider is used to configure and manage your strongDM account. It provides resources and datasources that allow you to:

  • Register gateways
  • Enroll databases and servers
  • Grant access
  • Create and suspend users
  • Manage roles

Requirements

Authentication

If you don't already have them you will need to generate a set of API keys, instructions are here: API Credentials

Environment Variables

You can provide your credentials via the SDM_API_ACCESS_KEY and SDM_API_SECRET_KEY environment variables.

$ export SDM_API_ACCESS_KEY="<access-key>"
$ export SDM_API_SECRET_KEY="<secret-key>"
$ terraform plan

Provider statement

provider "sdm" {}
Direct

If it is not possible to use environment variables add the api keys directly to the provider statement as so:

provider "sdm" {
	api_access_key = "ACCESS_KEY"
	api_secret_key = "SECRET_KEY"
}

Basic Example

Create a Gateway

resource "sdm_node" "example_gateway" {
    gateway {
        name = "example gateway"
        listen_address = "localhost:5000"
        bind_address = "0.0.0.0:5000"
    }
}
$ terraform plan
$ terraform apply

Contributions

Currently, we are not accepting pull requests directly to this repository, but our users are some of the most resourceful and ambitious folks out there. So, if you have something to contribute, find a bug, or just want to give us some feedback, please email support@strongdm.com.

Running integration tests

Important: These are integration tests. They will create and destroy real resources in your account!

First clone this repository.

In order to run the tests you must set these environment variables so that the provider can authenticate:

$ export SDM_API_ACCESS_KEY="<access-key>"
$ export SDM_API_SECRET_KEY="<secret-key>"

From the cloned repo, run:

$ cd terraform-provider-sdm
$ TF_ACC=yes go test ./sdm -v -count=1 -mod=vendor

You must set TF_ACC=yes in order to run tests. IF TF_ACC=yes is not set all tests will pass without any action.

License

Mozilla Public License 2.0

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
sdm
Package sdm is a terraform provider for strongDM
Package sdm is a terraform provider for strongDM
internal/sdk
Package sdm implements an API client to strongDM restful API.
Package sdm implements an API client to strongDM restful API.

Jump to

Keyboard shortcuts

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