boltops-tools / terraspace

Terraspace: The Terraform Framework
https://terraspace.cloud
Apache License 2.0
674 stars 46 forks source link

[FEATURE] Allow setting source mirror for rubygems.org #319

Open fl-max opened 1 year ago

fl-max commented 1 year ago

Summary

I am by no means a Ruby developer but after reading the docs extensively and performing trial & error with ~/.gemrc, gem source -a ..., etc., there does not seem to be a way to set the source registry for the Gemfile that is created for a new project. This prevents Organizations who are unable to reach out to public repos (air-gap) from using the tool completely. By adding the ability to set the source registry, it would allow you to pull Gems from mirrors such as an internal Artifactory.

Motivation

This will enable many Enterprise users who are bound to internal, mirrored registries to be able to use the tool.

Guide-level explanation

I think this could be accomplished in one of (at least) two ways:

  1. add a command line switch to terraspace such as --gem-mirror to indicate an alternate gem source
  2. pull sources listed in ~/.gemrc

Reference-level explanation

Drawbacks

Unresolved Questions