GithubHelp home page GithubHelp logo

isabella232 / terraform-provider-rollbar Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rollbar/terraform-provider-rollbar

1.0 0.0 0.0 7.91 MB

Terraform provider for Rollbar

Home Page: https://rollbar.com

License: MIT License

Makefile 1.59% Go 95.48% Shell 0.56% HCL 1.93% Dockerfile 0.44%

terraform-provider-rollbar's Introduction

Terraform provider for Rollbar

The Rollbar provider allows Terraform to control resources on Rollbar.com, the Continuous Code Improvement Platform.

The provider allows you to manage your Rollbar projects, tokens, users, and teams with ease. It must be configured with the proper credentials before it can be used.

Status

Build & Test Coverage Status CodeQL ShiftLeft Scan Maintainability Test Coverage Go Report Card

Usage

Example usage:

# Install Rollbar provider from Terraform Registry
terraform {
  required_providers {
    rollbar = {
      source  = "rollbar/rollbar"
    }
  }
}

# Configure the Rollbar provider
provider "rollbar" {
  api_key = "YOUR_API_KEY"
}

# Create a team
resource "rollbar_team" "frontend" {
  name = "frontend-team"
}

# Create a project and assign the team
resource "rollbar_project" "frontend" {
  name         = "react-frontend"
  team_ids = [rollbar_team.frontend.id]
}

See the docs for detailed usage information.

Debugging

Enable writing debug log to /tmp/terraform-provider-rollbar.log by setting an environment variable:

export TERRAFORM_PROVIDER_ROLLBAR_DEBUG=1
terraform apply   # or any command that calls the Rollbar provider

This is necessary because Terraform providers aren’t actually plugins - they don’t get loaded into the running Terraform process. Rather a provider is a stand alone program that is started as a child processes and communicates with Terraform via gRPC. Anything that child process writes to stdout/stderr is lost. So if we want debug logging we must write to a file.

Development

Requirements

  • Terraform 0.12.x, 0.13.x, or 0.14.x
  • Go 1.14.x, 1.15.x

See Quick Tests workflow for details of version compatibility testing.

Building locally

Run make build to build the provider from source.

Run make install to build from source then install the provider locally for usage by Terraform.

Folder ./example contains example Terraform configuration. To use this config with a locally built provider, copy file provider.tf.local to overwrite file provider.tf. Then run terraform init to initialize Terraform with the provider.

Running make plan, make apply, or make destroy will:

  • Build the provider from your working directory, and install for local Terraform.
  • Setup Terraform configuration to use the freshly built provider
  • Run terraform <plan|apply|destroy> in the examples folder with debug logging enabled.
  • Display the logs on completion.

Continuous Delivery

We use semantic-release for continuous delivery. When a PR is merged into master the Semantic Release workflow is triggered. If relevant Conventional Commits annotations are found in the Git log, semantic-release creates a new release and calls GoReleaser to build the binaries.

This way no human is directly involved in the release process and the releases are guaranteed to be unromantic and unsentimental.

-- from the semantic-release docs

After a new release has been created by semantic-release, it may take up to 10 minutes for the provider binaries to be built and attached by GoReleaser.

Terraform Versions

Several Makefile targets build the provider inside a Docker container, then test it against different versions of Terraform. Environment variable ROLLBAR_API_KEY must be set.

  • make terraform012 - Terraform 0.12.x
  • make terraform013 - Terraform 0.13.x
  • make terraform014 - Terraform 0.14.x

License

This is Free Software, released under the terms of the MIT license.

History

Derived from babbel/terraform-provider-rollbar and jmcvetta/terraform-provider-rollbar

terraform-provider-rollbar's People

Contributors

coryvirok avatar dependabot-preview[bot] avatar dependabot[bot] avatar fmasuhr avatar graffzon avatar jmcvetta avatar jtsaito avatar parabolic avatar

Stargazers

 avatar

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.