Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Terrascan does not support to download modules via SSH #621

Closed
sachinar opened this issue Mar 16, 2021 · 3 comments
Closed

Terrascan does not support to download modules via SSH #621

sachinar opened this issue Mar 16, 2021 · 3 comments

Comments

@sachinar
Copy link
Contributor

sachinar commented Mar 16, 2021

  • terrascan version: 1.4.0
  • Operating System: docker image (accurics/terrascan:1.4.0 )

Description

We are trying to use terrascan for our terraform repo. We are downloading modules through ssh.

What I Did

- /go/bin/terrascan init
- /go/bin/terrascan scan --use-colors t .
2021-03-15T09:52:56.710Z	error	commons/load-dir.go:109	failed to download remote module "git::ssh://git@gitlab.com/global-terraform0.12-modules.git//tiller". error: 'error downloading 'ssh://git@gitlab.com/global-terraform0.12-modules.git': /usr/bin/git exited with 128: Cloning into '/tmp/j8ipfe'...
@sachinar
Copy link
Contributor Author

sachinar commented Mar 17, 2021

Hi Team,

I tried to install openssh it worked for me.

Below is the Dockerfile for same

FROM accurics/terrascan:1.4.0
ENTRYPOINT []
USER root 
RUN apk add --no-cache openssh
WORKDIR /home/terrascan
USER terrascan
RUN mkdir -p .ssh && chown -R terrascan:terrascan .ssh
CMD ["server", "--log-type", "json"]

Can you guys just add openssh to docker image?

Created docker image can be downloaded with this name and tag.
sachinar/terrascan:1.4.0

@kanchwala-yusuf
Copy link
Contributor

Thanks @sachinar for your contribution!

@sachinar
Copy link
Contributor Author

@kanchwala-yusuf Please share the image tag for this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants