mirror of
https://github.com/ivabus/pantry
synced 2024-11-22 08:25:07 +03:00
parent
8409af5069
commit
154063c107
2 changed files with 48 additions and 0 deletions
11
projects/terratag.io/example.tf
Normal file
11
projects/terratag.io/example.tf
Normal file
|
@ -0,0 +1,11 @@
|
|||
provider "aws" {
|
||||
region = "us-east-1"
|
||||
}
|
||||
|
||||
resource "aws_s3_bucket" "bucket" {
|
||||
bucket = "my-tf-test-bucket"
|
||||
|
||||
tags = {
|
||||
Name = "My bucket"
|
||||
}
|
||||
}
|
37
projects/terratag.io/package.yml
Normal file
37
projects/terratag.io/package.yml
Normal file
|
@ -0,0 +1,37 @@
|
|||
distributable:
|
||||
url: https://github.com/env0/terratag/archive/refs/tags/v{{version}}.tar.gz
|
||||
strip-components: 1
|
||||
|
||||
versions:
|
||||
github: env0/terratag
|
||||
strip: /^v/
|
||||
|
||||
dependencies:
|
||||
terraform.io: ">=0.12"
|
||||
curl.se/ca-certs: '*'
|
||||
|
||||
build:
|
||||
dependencies:
|
||||
go.dev: ^1.21
|
||||
env:
|
||||
CGO_ENABLED: 0
|
||||
LDFLAGS:
|
||||
- -extldflags=-static
|
||||
- -w
|
||||
- -s
|
||||
- -X=main.version=v{{version}}
|
||||
script:
|
||||
- go build -v -ldflags="$LDFLAGS" -o terratag ./cmd/terratag
|
||||
- mkdir -p "{{ prefix }}"/bin
|
||||
- mv terratag "{{ prefix }}"/bin
|
||||
|
||||
provides:
|
||||
- bin/terratag
|
||||
|
||||
test:
|
||||
script:
|
||||
- test "$(terratag -version)" = "Terratag v{{version}}"
|
||||
- terraform init
|
||||
- terratag -tags="env=dev,tenant=clientA"
|
||||
- test -f example.terratag.tf
|
||||
- test -f example.tf.bak
|
Loading…
Reference in a new issue