Amazon Linux上的资产预编译

时间:2013-08-31 01:46:29

标签: ruby-on-rails amazon-ec2 precompile

我在一个小的amazon linux实例上安装了locomotivecms app。我跑了以下来预编译资产:

bundle exec rake assets:precompile

这已经过了半个小时,资产仍在进行预编译。以下是我到目前为止在终端上的内容:

[ec2-user@domU-12-31-39-09-15-88 locomotivecms]$ bundle exec rake assets:precompile
/home/ec2-user/.rvm/rubies/ruby-1.9.3-p448/bin/ruby /home/ec2-user/.rvm/gems/ruby-1.9.3-p448/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
which: no convert in (/home/ec2-user/.rvm/gems/ruby-1.9.3-p448/bin:/home/ec2-user/.rvm/gems/ruby-1.9.3-p448@global/bin:/home/ec2-user/.rvm/rubies/ruby-1.9.3-p448/bin:/home/ec2-user/.rvm/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/opt/aws/bin:/home/ec2-user/bin)
which: no identify in (/home/ec2-user/.rvm/gems/ruby-1.9.3-p448/bin:/home/ec2-user/.rvm/gems/ruby-1.9.3-p448@global/bin:/home/ec2-user/.rvm/rubies/ruby-1.9.3-p448/bin:/home/ec2-user/.rvm/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/opt/aws/bin:/home/ec2-user/bin)
mkdir -p /home/ec2-user/locomotivecms/public/assets
cp -rp /home/ec2-user/.rvm/gems/ruby-1.9.3-p448/gems/locomotive-tinymce-rails-3.5.8.2/vendor/assets/javascripts/tinymce /home/ec2-user/locomotivecms/public/assets
mkdir -p /home/ec2-user/locomotivecms/public/assets
cp -rp /home/ec2-user/.rvm/gems/ruby-1.9.3-p448/gems/locomotive-aloha-rails-0.23.2.2/vendor/assets/javascripts/aloha /home/ec2-user/locomotivecms/public/assets
which: no convert in (/home/ec2-user/.rvm/gems/ruby-1.9.3-p448/bin:/home/ec2-user/.rvm/gems/ruby-1.9.3-p448@global/bin:/home/ec2-user/.rvm/rubies/ruby-1.9.3-p448/bin:/home/ec2-user/.rvm/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/opt/aws/bin:/home/ec2-user/bin)
which: no identify in (/home/ec2-user/.rvm/gems/ruby-1.9.3-p448/bin:/home/ec2-user/.rvm/gems/ruby-1.9.3-p448@global/bin:/home/ec2-user/.rvm/rubies/ruby-1.9.3-p448/bin:/home/ec2-user/.rvm/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/opt/aws/bin:/home/ec2-user/bin)

哪些命令意味着花时间为每个正在编译的文件找到rake可执行文件?

1 个答案:

答案 0 :(得分:2)

好像你没有安装imagemagick。

根据您的发行版,它应该是sudo yum install ImageMagick ImageMagick-develsudo apt-get install imagemagick

您可以通过发出命令convertidentify来测试它是否已成功安装。

但是,文档建议您在自己的本地计算机上预编译,而不是在远程服务器上。这意味着,您首先在自己的计算机上发出bundle exec rake assets:precompile。这样可以避免在远程服务器上进行预编译。