boltops-tools / terraspace

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

Error when creating a new project #256

Closed mmclane closed 2 years ago

mmclane commented 2 years ago

Checklist

My Environment

Software Version
Operating System Pop!_OS 22.04 LTS
Terraform v1.0.6
Terraspace 2.1.5
Ruby 2.0.2p17

Expected Behaviour

I expected to be able to successfully create a new project when following the instructures here: https://terraspace.cloud/docs/learn/aws/new-project/

Current Behavior

terraspace new project infra --plugin aws --examples
=> Creating new project called infra
      create  infra
      create  infra/.gitignore
      create  infra/Gemfile
      create  infra/README.md
      create  infra/Terrafile
      create  infra/config/app.rb
=> Installing dependencies with: bundle install
sh: 1: bundle: not found
LoadError: cannot load such file -- terraspace_plugin_aws
ERROR: Unable to require plugin terraspace_plugin_aws
Are you sure you the plugin exists and you specified the right plugin option.
You specified --plugin aws

Step-by-step reproduction instructions

Fresh install Installed terraspace with gem install. I did have to install ruby-dev for that to be successful. terraspace setup check runs successfully.

Code Sample

Solution Suggestion

mmclane commented 2 years ago

running the following fixed my error. The website might give guidance.

sudo gem install terraspace_plugin_aws
tongueroo commented 2 years ago

It looks like your Ruby install is quite old. Guessing it’s whatever Ruby system version. In super old Ruby versions, bundler was not package as part of Ruby, hence the bundle command is not found. Try installing Ruby 3+ It’s the recommended version