/
Portfile
42 lines (33 loc) · 1.45 KB
/
Portfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
PortSystem 1.0
PortGroup golang 1.0
go.setup github.com/tfsec/tfsec 1.28.6 v
github.tarball_from archive
revision 0
description Security scanner for your Terraform code
long_description {*}${description}. tfsec uses static analysis of your \
Terraform templates to spot potential security issues.
categories security sysutils
installs_libs no
license MIT
maintainers {gmail.com:herby.gillot @herbygillot} \
openmaintainer
checksums rmd160 b9a557bc418984bbf577eff8c0dd49fc11413715 \
sha256 dd33335bb442541a54b2d05186f91489a324a2754b2b790b423d41a8c8c2a53d \
size 6544301
# Allow Go to fetch dependencies at build time
go.offline_build no
build.env-append TRAVIS_TAG=${version}
build.cmd "go mod vendor && make build"
patch {
# Delete lines building for Linux or Windows
reinplace -E {/GOOS=(linux|windows)/ d} ${worksrcpath}/scripts/build.sh
}
destroot {
foreach tfsec_build_bin [glob ${worksrcpath}/bin/${os.platform}/*] {
set tfsec_install_bin \
[file tail [strsed $tfsec_build_bin s/-${os.platform}.*//]]
xinstall -m 0755 \
${tfsec_build_bin} ${destroot}${prefix}/bin/${tfsec_install_bin}
}
}