From a0e65256e93dac17d221bf788507285ba0eca632 Mon Sep 17 00:00:00 2001 From: Luiz Angelo Daros de Luca Date: Sat, 4 Oct 2014 16:54:24 -0300 Subject: ruby: wrap script to disable gems if not installed ruby, by default, try to load gems on start. If not present, it fails. As gems brings many deps, this make ruby unsuitable for routers limited resources. ruby can avoid to load gems with the option "--disable-gems". So, a wrap script in the place of /usr/bin/ruby adds this option if gems are not found. Also add vendor/site directories Signed-off-by: Luiz Angelo Daros de Luca --- lang/ruby/files/ruby | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 lang/ruby/files/ruby (limited to 'lang/ruby/files') diff --git a/lang/ruby/files/ruby b/lang/ruby/files/ruby new file mode 100644 index 000000000..e4904fc2f --- /dev/null +++ b/lang/ruby/files/ruby @@ -0,0 +1,5 @@ +#!/bin/sh +if ! [ -r "@RUBY_LIBPATH@/rubygems.rb" ]; then + exec @RUBY_BINPATH@ --disable-gems "$@" +fi +exec @RUBY_BINPATH@ "$@" -- cgit v1.2.3