drone-terraform-github-commenter

command module
v0.0.0-...-71dc128 Latest Latest
Warning

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

Go to latest
Published: Nov 11, 2020 License: MIT Imports: 25 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

drone-terraform-github-commenter

This plugin for Drone posts a comment to a GitHub PR, with the Terraform plan output.

Configuration

The following parameters are used to configure the plugin:

  • title: The title of the comment. Default is Terraform Plan Output.
  • mode: The display mode of the comment. Default is full. See below.
  • recreate: A flag to recreate the comment every time, otherwise comment is updated based on the title. Default is false.
  • issue_num: The PR or Issue number to post the comment. Optional.
  • root_dir: The root directory of where the Terraform plan ran. Default is .
  • tf_data_dir: The data directory where Terraform stores providers, plugins, and modules. Default is .terraform.
  • tf_version: The Terraform version to download and use, when not provided uses the prepackaged Terraform in the Docker image. Optional.
  • base_url: The GitHub Base URL, for use with GitHub Enterprise Server. Default is https://api.github.com/.
Display mode

There are three types of modes:

  • summary: Only shows total resources that will be created, updated or destroyed.
  • simple: List resources that will be changed, and displays summary.
  • full: Shows full plan.
Secrets

All the following secrets are optional:

  • github_username
  • github_password
  • github_token or github_release_api_key

This plugin is setup to use the GitHub credentials from Drone's netrc environment variables.

Drone configuration example
pipeline:
  plan:
    image: jmccann/drone-terraform:6.3-0.12.20
    actions:
      - validate
      - plan

  comment-plan:
    image: robertstettner/drone-terraform-github-commenter

Usage with Drone secret:

pipeline:
  plan:
    image: jmccann/drone-terraform:5
    actions:
      - validate
      - plan

  comment-plan:
    image: robertstettner/drone-terraform-github-commenter
+   secrets: [ github_token ]

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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