Qiita Teams that are logged in
You are not logged in to any team

Log in to Qiita Team
Community
OrganizationEventAdvent CalendarQiitadon (β)
Service
Qiita JobsQiita ZineQiita Blog
0
Help us understand the problem. What are the problem?

More than 5 years have passed since last update.

@adans

railsコマンドでInsecure Error

CentOSにrbenvを使ってruby環境をセットアップし、rootですべておこない、rails newできるところまでいきました。

この後、wheelにいる一般ユーザでrails newしようとしましたがInsecure operationでアプリを作れません。
gem env もエラーが返ります。

/usr/local/rbenv にインストールするのには無理があるのでしょうか…ご助言いただけないでしょうか><

環境
CentOS6.3

$ ruby -v
ruby 1.9.3p484 (2013-11-22 revision 43786) [i686-linux]
$ rails -v (このコマンドはrootで確認)
Rails 3.2.13

rbenvインストール先
/usr/local/rbenv/bin/rbenv

通してあるパス (echo $PATH)
/usr/local/rbenv/bin:
/usr/kerberos/sbin:
/usr/local/bin:
/usr/local/rbenv/shims:
/usr/local/rbenv/bin:
/usr/kerberos/bin:
/usr/local/bin:
/bin:
/usr/bin

インストール先権限
/usr 755
/usr/local 755
/usr/local/rbenv 755

$ rails new で返ってくるエラー
/usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:710:in []': Insecure operation - [] (SecurityError)
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:710:in
block in each_gemspec'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:709:in each'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:709:in
each_gemspec'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:717:in each_stub'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:736:in
stubs'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:255:in matching_specs'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:279:in
to_specs'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:309:in to_spec'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_gem.rb:53:in
gem'
from /usr/local/rbenv/versions/1.9.3-p484/bin/rails:22:in `'

$ gem env で返ってくるエラー
/usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/config_file.rb:329:in exist?': Insecure operation - exist? (SecurityError)
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/config_file.rb:329:in
load_file'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/config_file.rb:196:in initialize'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/gem_runner.rb:74:in
new'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/gem_runner.rb:74:in do_configuration'
from /usr/local/rbenv/versions/1.9.3-p484/lib/ruby/site_ruby/1.9.1/rubygems/gem_runner.rb:39:in
run'
from /usr/local/rbenv/versions/1.9.3-p484/bin/gem:21:in `'

Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
0
Help us understand the problem. What are the problem?