mozilla / ssh_scan

DEPRECATED - A prototype SSH configuration and policy scanner (Blog: https://mozilla.github.io/ssh_scan/)
Mozilla Public License 2.0
792 stars 105 forks source link

Fix 510: tweak Dockerfile to work around upstream environment issue with Ruby 2.7.0 #511

Closed rrazor closed 4 years ago

rrazor commented 4 years ago

Overview

This PR resolves #510 by working around the non-apk-provided ruby 2.7.0 from alpine:ruby using environment variables.

I did the following:

Testing

There are no automated tests but I have manually verified that the following results in JSON output:

$ docker build -t ssh_scan .
$ docker run -it ssh_scan /app/bin/ssh_scan -t sshscan.rubidus.com
[...]

Additional steps

A better way to fix this may be to submit an upstream PR to the maintainers of alpine:ruby so that they can set the correct GEM_* environment variables according to the source-built version of ruby they choose to use.

For now, however, I believe this will correct the issue as reported.

claudijd commented 4 years ago

Thanks for the fix!