diff --git a/.gitignore b/.gitignore index e69de29..2749df5 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1,27 @@ +# Compiled Object files, Static and Dynamic libs (Shared Objects) +*.o +*.a +*.so + +# Folders +_obj +_test + +# Architecture specific extensions/prefixes +*.[568vq] +[568vq].out + +*.cgo1.go +*.cgo2.c +_cgo_defun.c +_cgo_gotypes.go +_cgo_export.* + +_testmain.go + +*.exe +*.test +*.prof + +coverage.out +drone-terraform diff --git a/MAINTAINERS b/MAINTAINERS new file mode 100644 index 0000000..0ecaf19 --- /dev/null +++ b/MAINTAINERS @@ -0,0 +1,46 @@ +[people] + [people.bradrydzewski] + name = "Brad Rydzewski" + email = "brad@drone.io" + login = "bradrydzewski" + [people.Bugagazavr] + name = "Kirill" + email = "" + login = "Bugagazavr" + [people.donny-dont] + name = "Don Olmstead" + email = "donny-dont@gmail.com" + login = "donny-dont" + [people.jackspirou] + name = "Jack Spirou" + email = "" + login = "jackspirou" + [people.msteinert] + name = "Mike Steinert" + email = "" + login = "msteinert" + [people.nlf] + name = "Nathan LaFreniere" + email = "" + login = "nlf" + [people.tboerger] + name = "Thomas Boerger" + email = "thomas@webhippie.de" + login = "tboerger" + [people.athieriot] + name = "Aurélien Thieriot" + email = "a.thieriot@gmail.com" + login = "athieriot" + +[org] + [org.core] + people = [ + "bradrydzewski", + "Bugagazavr", + "donny-dont", + "jackspirou", + "msteinert", + "nlf", + "tboerger", + "athieriot" + ] diff --git a/Makefile b/Makefile index d1cd996..0dc93e2 100644 --- a/Makefile +++ b/Makefile @@ -1,12 +1,14 @@ -.PHONY: clean deps fmt vet test docker +.PHONY: all clean deps fmt vet test docker EXECUTABLE ?= drone-terraform IMAGE ?= plugins/$(EXECUTABLE) -CI_BUILD_NUMBER ?= 0 +COMMIT ?= $(shell git rev-parse --short HEAD) -LDFLAGS = -X "main.buildDate=$(shell date -u '+%Y-%m-%d %H:%M:%S %Z')" +LDFLAGS = -X "main.buildCommit=$(COMMIT)" PACKAGES = $(shell go list ./... | grep -v /vendor/) +all: deps build test + clean: go clean -i ./... diff --git a/README.md b/README.md index 101123a..dc0ca3a 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,123 @@ -# Drone Terraform Deploy Plugin +# drone-terraform -This project provides a [Drone](drone.io) plugin docker image that contains the [Terraform](terraform.io) binaries and a small Go app that receives the Drone meta-data and executes Terraform commands. +[![Build Status](http://beta.drone.io/api/badges/drone-plugins/drone-terraform/status.svg)](http://beta.drone.io/drone-plugins/drone-terraform) +[![Coverage Status](https://aircover.co/badges/drone-plugins/drone-terraform/coverage.svg)](https://aircover.co/drone-plugins/drone-terraform) +[![](https://badge.imagelayers.io/plugins/drone-terraform:latest.svg)](https://imagelayers.io/?images=plugins/drone-terraform:latest 'Get your own badge on imagelayers.io') -Documentation for Drone Plugin development can be found here: http://readme.drone.io/plugin/ +Drone plugin to execute Terraform plan and apply. For the usage information and a listing of the available options please take a look at [the docs](DOCS.md). -See [DOCS](DOCS.md) for details on this plugin's configuration and usage. +## Binary + +Build the binary using `make`: + +``` +make deps build +``` + +### Example + +```sh +./drone-terraform <