New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

passenger-install-apache2-module doesn't work on ruby 2.0 #71

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
@id774
Copy link

id774 commented Feb 20, 2013

Now passenger-install-apache2-module failed on ruby 2.0


Checking for required software...

  • GNU C++ compiler... found at /usr/bin/g++
  • Curl development headers with SSL support... found
  • OpenSSL development headers... found
  • Zlib development headers... found
  • Ruby development headers... found
  • OpenSSL support for Ruby... found
  • RubyGems... found
  • Rake... found at /opt/ruby/2.0/bin/rake
  • rack... found
  • Apache 2... found at /usr/sbin/apache2
  • Apache 2 development headers... found at /usr/bin/apxs2
  • Apache Portable Runtime (APR) development headers... found at /usr/bin/apr-1-config
  • Apache Portable Runtime Utility (APU) development headers... found at /usr/bin/apu-1-config

Compiling and installing Apache 2 module...
(Omitted)

rake aborted!
cannot load such file -- rubygems/builder

(See full trace by running task with --trace)


It looks like something went wrong

This patch will fix this issue.
So, passenger will well done on ruby 1.9 and 2.0.

@ohenak

This comment has been minimized.

Copy link

ohenak commented Feb 24, 2013

I believe passenger-install-nginx-module has the same problem.

/usr/local/rvm/wrappers/ruby-2.0.0-p0/rake nginx:clean nginx RELEASE=yes
rake aborted!
cannot load such file -- rubygems/builder
/usr/local/rvm/gems/ruby-2.0.0-p0/gems/passenger-3.0.19/build/gempackagetask.rb:12:in <top (required)>' /usr/local/rvm/gems/ruby-2.0.0-p0/gems/passenger-3.0.19/build/basics.rb:41:in<top (required)>'
/usr/local/rvm/gems/ruby-2.0.0-p0/gems/passenger-3.0.19/Rakefile:24:in <top (required)>' /usr/local/rvm/gems/ruby-2.0.0-p0/bin/ruby_noexec_wrapper:14:ineval'
/usr/local/rvm/gems/ruby-2.0.0-p0/bin/ruby_noexec_wrapper:14:in `

'
(See full trace by running task with --trace)

@FooBarWidget

This comment has been minimized.

Copy link
Member

FooBarWidget commented Feb 24, 2013

We should get rid of the Rake package tasks anyway and replace it with a gemspec. The current package task just slows everything down by scanning the directory tree on every Rake invocation even when it's unnecessary.

@FooBarWidget

This comment has been minimized.

Copy link
Member

FooBarWidget commented Feb 24, 2013

Issue 845 has been opened to track this problem: http://code.google.com/p/phusion-passenger/issues/detail?id=846

@nobu

This comment has been minimized.

Copy link

nobu commented Feb 25, 2013

It doesn't seem a nice idea to select by RUBY_VERSION.
The difference comes from Rubygems change, and could happen on 1.9 with recent Rubygems, I guess.

@id774

This comment has been minimized.

Copy link

id774 commented Feb 25, 2013

I tried again on ruby1.9.3-p385, rubygems 2.0.0 and Phusion Passenger Apache 2 module installer, v3.0.18.
It finished successfully.
This problem didn't occur.

@FooBarWidget

This comment has been minimized.

Copy link
Member

FooBarWidget commented Feb 25, 2013

Fixed in commit 9313cb0.

@lsgd

This comment has been minimized.

Copy link

lsgd commented Feb 25, 2013

How can I install this latest version?
With "gem passenger" it doesn't work.

@FooBarWidget

This comment has been minimized.

Copy link
Member

FooBarWidget commented Feb 25, 2013

To install a beta version: http://www.modrails.com/documentation/Users%20guide%20Apache.html#_installation (covers beta installation as well)
To install directly from a git repository: see the README.

@iamfree-com

This comment has been minimized.

Copy link

iamfree-com commented Mar 1, 2013

This is what worked for me.

steps to install Passenger gem from the master branch.

git clone https://github.com/FooBarWidget/passenger.git
cd passenger
gem build passenger.gemspec
gem install passenger-3.9.5.rc3.gem (or type your actual built gem name)

thanks Phusion Passenger, you guys rule. cheers

@func0der

This comment has been minimized.

Copy link

func0der commented Mar 3, 2013

Yep. Cloning from repository helped me out.
It's time to make a Ruby2.0 stable ;)

Thanks guys.

@lazywei

This comment has been minimized.

Copy link

lazywei commented Mar 4, 2013

@riverlook 's solution works for me!

@bzlom

This comment has been minimized.

Copy link

bzlom commented Mar 11, 2013

Hello, i'm a newbie in ruby, rails, and passenger.
I have manually copied the updated file to the required folders and the passenger-install-apache2-module command completed successfully. The only question i have - since there is mentioned the magic word 'patch' - can we somehow apply the patch, like through some shell script or some *.rb file. Or this was just an expression that meant - you should switch gempackagetask.rb with the one in this thread?

Regards,

@FooBarWidget

This comment has been minimized.

Copy link
Member

FooBarWidget commented Mar 11, 2013

No patching is necessary. It's very simple: if you want to use Phusion Passenger on Ruby 2.0, install 4.0.0 RC 4 as follows:

sudo gem install passenger --pre
sudo passenger-install-apache2-module
@devbau

This comment has been minimized.

Copy link

devbau commented Apr 16, 2013

I had an issue with ruby 2.0 and passenger

rake aborted!
cannot load such file -- rubygems/builder

installing passenger from latest repo solved the issue

@przbadu

This comment has been minimized.

Copy link

przbadu commented Sep 27, 2013

Tasks: TOP => apache2 => buildout/agents/PassengerHelperAgent => buildout/common/libpassenger_common/ApplicationPool2/Implementation.o
(See full trace by running task with --trace)

--------------------------------------------

It looks like something went wrong

Please read our Users guide for troubleshooting tips:

   /usr/local/lib/ruby/gems/1.9.1/gems/passenger-4.0.19/doc/Users guide Apache.html

If that doesn't help, please use our support facilities at:

   https://www.phusionpassenger.com

We'll do our best to help you.

I am trying to host my rails app into sub-domain that i have created. I am getting this error whenever I am trying to run:

sudo passenger-install-apache2-module

in that server. Don't know what is the issue. I have successfully installed passenger with

  sudo gem install passenger
@tinco

This comment has been minimized.

Copy link
Contributor

tinco commented Sep 28, 2013

Hi Pushpa Raj Badu,

Have you tried the tips on this page?

http://www.modrails.com/documentation/Users%20guide%20Nginx.html#env_vars_and_sudo

Kind regards,
Tinco

On Fri, Sep 27, 2013 at 2:12 PM, Pushpa Raj Badu
notifications@github.comwrote:

Tasks: TOP => apache2 => buildout/agents/PassengerHelperAgent => buildout/common/libpassenger_common/ApplicationPool2/Implementation.o
(See full trace by running task with --trace)


It looks like something went wrong

Please read our Users guide for troubleshooting tips:

/usr/local/lib/ruby/gems/1.9.1/gems/passenger-4.0.19/doc/Users guide Apache.html

If that doesn't help, please use our support facilities at:

https://www.phusionpassenger.com

We'll do our best to help you.

I am trying to host my rails app into sub-domain that i have created. I am
getting this error whenever I am trying to run:

sudo passenger-install-apache2-module

in that server. Don't know what is the issue. I have successfully
installed passenger with

sudo gem install passenger


Reply to this email directly or view it on GitHubhttps://github.com//pull/71#issuecomment-25240754
.

Phusion | Ruby & Rails deployment, scaling and tuning solutions

Web: http://www.phusion.nl/
E-mail: info@phusion.nl
Chamber of commerce no: 08173483 (The Netherlands)

@przbadu

This comment has been minimized.

Copy link

przbadu commented Sep 30, 2013

[deploy:update_code] exception while rolling back: Capistrano::ConnectionError, connection failed for: http://url/mydir/ (SocketError: getaddrinfo: Name or service not known)
connection failed for: http:/url/mydir/ (SocketError: getaddrinfo: Name or service not known)
@tinco

This comment has been minimized.

Copy link
Contributor

tinco commented Oct 1, 2013

Hi, I don't think this exception has anything to with Passenger. I think it
is failing to resolve a dns or connect to that subdomain.

On Mon, Sep 30, 2013 at 9:11 AM, Pushpa Raj Badu
notifications@github.comwrote:

Thanks Tinco. The problem is solved, but now getting another problem while
deploying to this sub-domain.

I tried

cap deploy

but getting something like this:

[Deprecation Warning] This API has changed, please hook deploy:create_symlink instead of deploy:symlink.

  • 2013-09-30 12:23:46 executing deploy' * 2013-09-30 12:23:46 executingdeploy:update' ** transaction: start * 2013-09-30 12:23:46 executing `deploy:update_code'
    executing locally: "git ls-remote https://github.com/anveshnarepo/techzoo.git master"Username for 'https://github.com': usernamePassword for 'https://anurag@anveshnatech.com@github.com':
    command finished in 18395ms
  • executing "git clone -b master --depth 1 https://github.com/anveshnarepo/techzoo.git /var/www/anveshnatech.com/public_html/edupdu/releases/20130930065405 && cd /var/www/anveshnatech.com/public_html/edupdu/releases/20130930065405 && git checkout -b deploy efee1836068954a3259d0b9088c42be78745a0bb && git submodule init && git submodule sync && export GIT_RECURSIVE=$([ ! "git --version" < "git version 1.6.5" ] && echo --recursive) && git submodule update --init $GIT_RECURSIVE && (echo efee1836068954a3259d0b9088c42be78745a0bb > /var/www/anveshnatech.com/public_html/edupdu/releases/20130930065405/REVISION)"**
    servers: ["http://anveshnatech.com/edupdu/"]*** [deploy:update_code] rolling back
  • executing "rm -rf /var/www/anveshnatech.com/public_html/edupdu/releases/20130930065405; true"
    servers: ["http://anveshnatech.com/edupdu/"]
    ** [deploy:update_code] exception while rolling back: Capistrano::ConnectionError, connection failed for: http://anveshnatech.com/edupdu/ (SocketError: getaddrinfo: Name or service not known)connection failed for: http://anveshnatech.com/edupdu/ (SocketError: getaddrinfo: Name or service not known)


Reply to this email directly or view it on GitHubhttps://github.com//pull/71#issuecomment-25341210
.

@idify

This comment has been minimized.

Copy link

idify commented Dec 5, 2013

I think this is because of a setting in your shell preferences. right click on console--- profile--preferences-title and command-- run command as login shell. close the terminal and issue gem install command again and follow fdefaul steps for passsenger and this time it should work

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