You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Operating System: Microsoft Hosted Agents for Azure Pipelines (Ubuntu 18.04 LTS)
### Description
As part of my pipeline definition, I install the latest terrascan version (1.7.0) in the agent and proceed to execute terrascan init & scan. Installation goes smoothly, but when terrascan init is executed the command crashes and the task is marked as error.
The only way I avoided this behavior is to install terrascan version 1.5.0 or earlier.
On digging a bit into this issue, it seems like an issue because of CGO. We have enabled CGO in terrascan due to a certain package dependency, have raised a #906 for fixing this issue.
### Description
As part of my pipeline definition, I install the latest terrascan version (1.7.0) in the agent and proceed to execute terrascan init & scan. Installation goes smoothly, but when terrascan init is executed the command crashes and the task is marked as error.
The only way I avoided this behavior is to install terrascan version 1.5.0 or earlier.
Thanks for your help/advice, Regards
Ignacio
### What I Did
In my pipeline I execute the following commands:
curl --location https://github.com/accurics/terrascan/releases/download/v1.7.0/terrascan_1.7.0_Linux_x86_64.tar.gz --output terrascan.tar.gz
tar -xf terrascan.tar.gz terrascan && rm terrascan.tar.gz
sudo install terrascan /usr/local/bin && rm terrascan
terrascan init -l debug
Terrascan init command fails, and the following error is generated:
2021-06-14T19:27:14.289Z debug cli/register.go:50 TERRASCAN_CONFIG:
2021-06-14T19:27:14.289Z debug config/config-reader.go:56 no config file specified
2021-06-14T19:27:14.289Z debug utils/policy.go:43 absolute rego_subdir path,
/home/vsts/work/1/s/jumpbox/pkg/policies/opa/rego
, does not fall under base repo path's/home/vsts/.terrascan
directory structure2021-06-14T19:27:14.289Z debug utils/policy.go:44 appending rego_subdir path:
pkg/policies/opa/rego
to the policy base path:/home/vsts/.terrascan
. checking ...2021-06-14T19:27:14.289Z debug config/global.go:118 global config loaded
2021-06-14T19:27:14.289Z debug initialize/run.go:39 initializing terrascan
2021-06-14T19:27:14.488Z debug initialize/run.go:68 downloading policies
2021-06-14T19:27:14.488Z debug initialize/run.go:70 base directory path : /home/vsts/.terrascan
2021-06-14T19:27:14.488Z debug initialize/run.go:71 policy directory path : /home/vsts/.terrascan/pkg/policies/opa/rego
2021-06-14T19:27:14.488Z debug initialize/run.go:72 policy repo url : https://github.com/accurics/terrascan.git
2021-06-14T19:27:14.488Z debug initialize/run.go:73 policy repo git branch : master
2021-06-14T19:27:14.488Z debug initialize/run.go:77 cloning terrascan repo at /home/vsts/.terrascan
fatal error: unexpected signal during runtime execution
[signal SIGSEGV: segmentation violation code=0x1 addr=0x63 pc=0x7f37a3db1448]
runtime stack:
runtime.throw(0x2c37ad2, 0x2a)
/usr/lib/go-1.15/src/runtime/panic.go:1116 +0x72
runtime.sigpanic()
/usr/lib/go-1.15/src/runtime/signal_unix.go:726 +0x4ac
The text was updated successfully, but these errors were encountered: