Deployment: Consider an rbenv or similar cookbook to avoid limiting to ruby 1.9.* #373

Closed
CloCkWeRX opened this Issue Jun 8, 2014 · 9 comments

Comments

Projects
None yet
3 participants
Contributor

CloCkWeRX commented Jun 8, 2014

https://github.com/RiotGames/rbenv-cookbook is pretty handy, and it lets you avoid things like:

%w("ruby1.9.1" "ruby1.9.1-dev" "libxslt-dev" "libxml2-dev" "curl" "libmysqlclient-dev" "libffi-dev" "libssl-dev").each do |pkg|
  package("#{pkg}")
end

bash "Setting default ruby and gem versions to 1.9" do
  code <<-EOH
    if [ $(readlink /usr/bin/ruby) != "ruby1.9.1" ]
    then
      update-alternatives --set ruby /usr/bin/ruby1.9.1
    fi

    if [ $(readlink /usr/bin/gem) != "gem1.9.1" ]
    then
      update-alternatives --set gem /usr/bin/gem1.9.1
    fi
  EOH
end

@CloCkWeRX CloCkWeRX changed the title from Deployment: Consider an rbenv or similar cookbook to avoid limiting to ruby 1.9.3 to Deployment: Consider an rbenv or similar cookbook to avoid limiting to ruby 1.9.* Jun 8, 2014

Owner

cantino commented Jun 8, 2014

I'm very open to adding additional deployment strategies as long as someone wants to maintain them. :)

I actually just use Capistrano and RVM, as described here: https://github.com/cantino/huginn/wiki/Deployment-with-Capistrano%2C-Unicorn%2C-nginx%2C-Foreman%2C-and-Upstart

Member

0xdevalias commented Jun 8, 2014

If you look in my chef branch I actually have a rewrite in progress (but stalled) that uses rbenv.—
Sent from Mailbox

On Mon, Jun 9, 2014 at 8:33 AM, Andrew Cantino notifications@github.com
wrote:

I'm very open to adding additional deployment strategies as long as someone wants to maintain them. :)

I actually just use Capistrano and RVM, as described here: https://github.com/cantino/huginn/wiki/Deployment-with-Capistrano%2C-Unicorn%2C-nginx%2C-Foreman%2C-and-Upstart

Reply to this email directly or view it on GitHub:
cantino#373 (comment)

Member

0xdevalias commented Jun 8, 2014

See my chef updates issue/branch. (Related)—
Sent from Mailbox

On Sun, Jun 8, 2014 at 11:42 PM, CloCkWeRX notifications@github.com
wrote:

https://github.com/RiotGames/rbenv-cookbook is pretty handy, and it lets you avoid things like:

%w("ruby1.9.1" "ruby1.9.1-dev" "libxslt-dev" "libxml2-dev" "curl" "libmysqlclient-dev" "libffi-dev" "libssl-dev").each do |pkg|
  package("#{pkg}")
end
bash "Setting default ruby and gem versions to 1.9" do
  code <<-EOH
    if [ $(readlink /usr/bin/ruby) != "ruby1.9.1" ]
    then
      update-alternatives --set ruby /usr/bin/ruby1.9.1
    fi
    if [ $(readlink /usr/bin/gem) != "gem1.9.1" ]
    then
      update-alternatives --set gem /usr/bin/gem1.9.1
    fi
  EOH
end

Reply to this email directly or view it on GitHub:
cantino#373

Contributor

CloCkWeRX commented Jun 9, 2014

@alias1 Ah drat. I just did a bunch of refactoring to use it and DRY up
things! Also to add in centos. Will look at your work
On 09/06/2014 8:06 AM, "alias1" notifications@github.com wrote:

If you look in my chef branch I actually have a rewrite in progress (but
stalled) that uses rbenv.—
Sent from Mailbox

On Mon, Jun 9, 2014 at 8:33 AM, Andrew Cantino notifications@github.com
wrote:

I'm very open to adding additional deployment strategies as long as
someone wants to maintain them. :)
I actually just use Capistrano and RVM, as described here:

https://github.com/cantino/huginn/wiki/Deployment-with-Capistrano%2C-Unicorn%2C-nginx%2C-Foreman%2C-and-Upstart

Reply to this email directly or view it on GitHub:
cantino#373 (comment)


Reply to this email directly or view it on GitHub
cantino#373 (comment).

Member

0xdevalias commented Jun 11, 2014

Will take a look at your stuff :)

Owner

cantino commented Jun 29, 2014

Status of this?

Contributor

CloCkWeRX commented Jun 29, 2014

Part of #377 at the moment. I've addressed a bit of the feedback, but haven't extensively retested. It probably needs a few more brave test pilots to see what I mucked up

Owner

cantino commented Jul 29, 2014

Merging these issues.

@cantino cantino closed this Jul 29, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment