change 'rvm install' calls not to try sudo if 'runas' is set to non-root user

This commit is contained in:
Marek Skrobacki 2013-10-16 11:52:46 +01:00 committed by Marek Skrobacki
parent d2f16e6c85
commit 347550ec12

View File

@ -111,6 +111,10 @@ def install_ruby(ruby, runas=None):
# git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0
# libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev autoconf libc6-dev
# libncurses5-dev automake libtool bison subversion ruby
if runas and runas != 'root':
_rvm('autolibs disable', ruby, runas=runas)
return _rvm('install --disable-binary', ruby, runas=runas)
else:
return _rvm('install', ruby, runas=runas)