aboutsummaryrefslogblamecommitdiffstats
path: root/community/terraform/APKBUILD
blob: e421f516a2f88828391862a4faf3b2b83bad1e22 (plain) (tree)
1
2
3
4
5
6
7
8
9
                                                   
                                                 
                                                      
                                                 

                                                  
             
        
                                                                                
                               
          
                 
                
                                                                                                
                                                    
                     
 
           
                               
                                                

                       

         

                                                                                                                               


         
                                                                                                             
                       


           
                                                                          

 
                                                                                                                                                                      
# Contributor: Thomas Boerger <thomas@webhippie.de>
# Contributor: Gennady Feldman <gena01@gmail.com>
# Contributor: Sergii Sadovyi <serg.sadovoi@gmail.com>
# Contributor: Galen Abell <galen@galenabell.com>
# Maintainer: Thomas Boerger <thomas@webhippie.de>
pkgname=terraform
pkgver=0.14.9
pkgrel=0
pkgdesc="Building, changing and combining infrastructure safely and efficiently"
url="https://www.terraform.io/"
arch="all"
license="MPL-2.0"
makedepends="go"
source="$pkgname-$pkgver.tar.gz::https://github.com/hashicorp/terraform/archive/v$pkgver.tar.gz"
builddir="$srcdir/src/github.com/hashicorp/$pkgname"
options="chmod-clean"

prepare() {
	mkdir -p ${builddir%/*}
	mv $srcdir/$pkgname-$pkgver "$builddir"/
	default_prepare
}

build() {
	GOPATH="$srcdir" go build -v -o bin/$pkgname \
		-mod=readonly -ldflags "-X main.GitCommit=v$pkgver -X github.com/hashicorp/terraform/version.Prerelease= -s -w"
}

check() {
	GOPATH="$srcdir" go list -mod=readonly . | xargs -t -n4 go test -mod=readonly -timeout=2m -parallel=4
	bin/$pkgname -v
}

package() {
	install -Dm755 "$builddir"/bin/$pkgname "$pkgdir"/usr/bin/$pkgname
}

sha512sums="224cec89180322902a3ff95bb1de5af7ecf351889fdc99ddc5c574bf9f61e7f3b9ba3eead870239fa4f977c6c337a322bbc2260af301295bad7b2d2fb28a0da1  terraform-0.14.9.tar.gz"