nginx Passenger Installation

daBee

Active Member

Reaction score: 7
Messages: 190

Hi folks. I can't seem to get www/nginx installed with Passenger on 10.1.

RVM is installed.

Code:
$ rvm gemset list

gemsets for ruby-2.2.3 (found in /home/rich/.rvm/gems/ruby-2.2.3)
=> (default)
   global

$ rvm list

rvm rubies

=* ruby-2.2.3 [ x86_64 ]

# => - current
# =* - current && default
#  * - default

$ rvm info

ruby-2.2.3:

  system:
    uname:       "FreeBSD shuttle.local 10.1-RELEASE FreeBSD 10.1-RELEASE #0 r274401: Tue Nov 11 21:02:49 UTC 2014     root@releng1.nyi.freebsd.org:/usr/obj/usr/src/sys/GENERIC  amd64"
    system:      "freebsd/10.1/x86_64"
    bash:        "/usr/local/bin/bash => GNU bash, version 4.3.42(1)-release (amd64-portbld-freebsd10.1)"
    zsh:         " => not installed"

  rvm:
    version:      "rvm 1.26.11 (latest) by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.io/]"
    updated:      "44 minutes 49 seconds ago"
    path:         "/home/rich/.rvm"

  ruby:
    interpreter:  "ruby"
    version:      "2.2.3p173"
    date:         "2015-08-18"
    platform:     "x86_64-freebsd10.1"
    patchlevel:   "2015-08-18 revision 51636"
    full_version: "ruby 2.2.3p173 (2015-08-18 revision 51636) [x86_64-freebsd10.1]"

  homes:
    gem:          "/home/rich/.rvm/gems/ruby-2.2.3"
    ruby:         "/home/rich/.rvm/rubies/ruby-2.2.3"

  binaries:
    ruby:         "/home/rich/.rvm/rubies/ruby-2.2.3/bin/ruby"
    irb:          "/home/rich/.rvm/rubies/ruby-2.2.3/bin/irb"
    gem:          "/home/rich/.rvm/rubies/ruby-2.2.3/bin/gem"
    rake:         "/home/rich/.rvm/rubies/ruby-2.2.3/bin/rake"

  environment:
    PATH:         "/home/rich/.rvm/gems/ruby-2.2.3/bin:/home/rich/.rvm/gems/ruby-2.2.3@global/bin:/home/rich/.rvm/rubies/ruby-2.2.3/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:/home/rich/bin:/home/rich/.rvm/bin"
    GEM_HOME:     "/home/rich/.rvm/gems/ruby-2.2.3"
    GEM_PATH:     "/home/rich/.rvm/gems/ruby-2.2.3:/home/rich/.rvm/gems/ruby-2.2.3@global"
    MY_RUBY_HOME: "/home/rich/.rvm/rubies/ruby-2.2.3"
    IRBRC:        "/home/rich/.rvm/rubies/ruby-2.2.3/.irbrc"
    RUBYOPT:      ""
    gemset:       ""
Here are the last lines of the ports installation:

Code:
mkdir -p 'buildout/ruby/ruby-2.2.3-x86_64-freebsd10.1/'
Unable to autodetect the currently active RVM gem set name. This could happen if you ran this program using 'sudo' instead of 'rvmsudo'. When using RVM, you're always supposed to use 'rvmsudo' instead of 'sudo!'.

Please try rerunning this program using 'rvmsudo'. If that doesn't help, please contact this program's author for support.
===>  Script "configure" failed unexpectedly.
Please report the problem to osa@FreeBSD.org [maintainer] and attach the
"/usr/ports/www/nginx/work/nginx-1.8.0/config.log" including the output of
the failure of your make command. Also, it might be a good idea to provide
an overview of all packages installed on your system (e.g. a
/usr/local/sbin/pkg-static info -g -Ea).
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/www/nginx
*** Error code 1

Stop.
make: stopped in /usr/ports/www/nginx
I never used sudo for RVM installation.

I'm a bit lost as to what to do. Any insight appreciated.

Cheers
 

junovitch@

Daemon
Developer

Reaction score: 615
Messages: 1,773

Can you post the following?
cd /usr/ports/www/nginx; make showconfig
and
cd /usr/ports/www/rubygem-passenger; make showconfig
 
OP
OP
daBee

daBee

Active Member

Reaction score: 7
Messages: 190

Code:
$  cd /usr/ports/www/nginx; make showconfig
===> The following configuration options are available for nginx-1.8.0_3,2:
     DEBUG=on: Build with debugging support
     DEBUGLOG=on: Enable debug log (--with-debug)
     FILE_AIO=off: Enable file aio
     IPV6=on: IPv6 protocol support
     GOOGLE_PERFTOOLS=off: Enable google perftools module
     HTTP=on: Enable HTTP module
     HTTP_ADDITION=off: Enable http_addition module
     HTTP_AUTH_REQ=off: Enable http_auth_request module
     HTTP_CACHE=on: Enable http_cache module
     HTTP_DAV=off: Enable http_webdav module
     HTTP_FLV=off: Enable http_flv module
     HTTP_GEOIP=on: Enable http_geoip module
     HTTP_GZIP_STATIC=off: Enable http_gzip_static module
     HTTP_GUNZIP_FILTER=off: Enable http_gunzip_filter module
     HTTP_IMAGE_FILTER=off: Enable http_image_filter module
     HTTP_PERL=off: Enable http_perl module
     HTTP_RANDOM_INDEX=off: Enable http_random_index module
     HTTP_REALIP=off: Enable http_realip module
     HTTP_REWRITE=on: Enable http_rewrite module
     HTTP_SECURE_LINK=off: Enable http_secure_link module
     HTTP_SSL=on: Enable http_ssl module
     HTTP_STATUS=on: Enable http_stub_status module
     HTTP_SUB=off: Enable http_sub module
     HTTP_XSLT=off: Enable http_xslt module
     MAIL=off: Enable IMAP4/POP3/SMTP proxy module
     MAIL_IMAP=off: Enable IMAP4 proxy module
     MAIL_POP3=off: Enable POP3 proxy module
     MAIL_SMTP=off: Enable SMTP proxy module
     MAIL_SSL=off: Enable mail_ssl module
     SPDY=off: Enable SPDY protocol support (SSL req.)
     THREADS=on: Enable threads support
     WWW=on: Enable html sample files
     AJP=off: 3rd party ajp module
     CACHE_PURGE=off: 3rd party cache_purge module
     CLOJURE=off: 3rd party clojure module
     CT=off: 3rd party cert_transparency module (SSL req.)
     ECHO=off: 3rd party echo module
     HEADERS_MORE=off: 3rd party headers_more module
     HTTP_ACCEPT_LANGUAGE=off: 3rd party accept_language module
     HTTP_ACCESSKEY=off: 3rd party http_accesskey module
     HTTP_AUTH_DIGEST=off: 3rd party http_authdigest module
     HTTP_AUTH_KRB5=off: 3rd party http_auth_gss module
     HTTP_AUTH_LDAP=off: 3rd party http_auth_ldap module
     HTTP_AUTH_PAM=off: 3rd party http_auth_pam module
     HTTP_DAV_EXT=off: 3rd party webdav_ext module
     HTTP_EVAL=off: 3rd party eval module
     HTTP_FANCYINDEX=off: 3rd party http_fancyindex module
     HTTP_FOOTER=off: 3rd party http_footer module
     HTTP_MOGILEFS=off: 3rd party mogilefs module
     HTTP_NOTICE=off: 3rd party notice module
     HTTP_PUSH=on: 3rd party push module
     HTTP_PUSH_STREAM=on: 3rd party push stream module
     HTTP_REDIS=off: 3rd party http_redis module
     HTTP_RESPONSE=off: 3rd party http_response module
     HTTP_SUBS_FILTER=off: 3rd party subs filter module
     HTTP_TARANTOOL=off: 3rd party tarantool upstream module
     HTTP_UPLOAD=on: 3rd party upload module
     HTTP_UPLOAD_PROGRESS=on: 3rd party uploadprogress module
     HTTP_UPSTREAM_FAIR=off: 3rd party upstream fair module
     HTTP_UPSTREAM_STICKY=off: 3rd party upstream sticky module
     HTTP_ZIP=off: 3rd party http_zip module
     ARRAYVAR=off: 3rd party array_var module
     DRIZZLE=off: 3rd party drizzlie module
     ENCRYPTSESSION=off: 3rd party encrypted_session module
     FORMINPUT=on: 3rd party form_input module
     GRIDFS=off: 3rd party gridfs module
     ICONV=off: 3rd party iconv module
     LET=off: 3rd party let module
     LUA=off: 3rd party lua module
     MEMC=on: 3rd party memc (memcached) module
     MODSECURITY=off: 3rd party mod_security module
     NAXSI=off: 3rd party naxsi module
     PASSENGER=on: 3rd party passenger module
     POSTGRES=on: 3rd party postgres module
     RDS_CSV=off: 3rd party rds_csv module
     RDS_JSON=off: 3rd party rds_json module
     REDIS2=off: 3rd party redis2 module
     RTMP=off: 3rd party rtmp module
     SET_MISC=off: 3rd party set_misc module
     SFLOW=off: 3rd party sflow module
     SHIBBOLETH=off: 3rd party shibboleth module
     SLOWFS_CACHE=off: 3rd party slowfs_cache module
     SMALL_LIGHT=off: 3rd party small_light module
     SRCACHE=off: 3rd party srcache module
     STATSD=off: 3rd party statsd module
     UDPLOG=off: 3rd party udplog (syslog) module
     XRID_HEADER=off: 3rd party x-rid header module
     XSS=off: 3rd party xss module
     VIDEO=on: Video module support
====> Video module support: you can only select none or one of them
     HTTP_MP4=off: Enable http_mp4 module
     HTTP_MP4_H264=on: 3rd party mp4/h264 module
===> Use 'make config' to modify these settings
Code:
 make showconfig
===> The following configuration options are available for rubygem-passenger-5.0.22:
     DEBUG=on: Build with debugging support
     SYMLINK=on: Create passenger symlink
====> Options available for the single SERVER: you have to select exactly one of them
     APACHE22=off: Build with apache22 support
     NGINX=on: Build with nginx support
===> Use 'make config' to modify these settings
 

junovitch@

Daemon
Developer

Reaction score: 615
Messages: 1,773

Strange. I built it with Ruby 2.1 just fine. Then I noticed you are using 2.2 and I built it with the 2.2.4 that is in ports as of today. I also built it with DEBUG and SYMLINK enabled for www/rubygem-passenger but I did not customize www/nginx past the PASSENGER option. Can you make rmconfig on both ports and just build with NGINX on www/rubygem-passenger and PASSENGER on www/nginx? Can you also update all other ports before doing so?
 
OP
OP
daBee

daBee

Active Member

Reaction score: 7
Messages: 190

OK, cleaned out the config, and it didn't work.

Code:
[Sun Dec 27 02:32:52 rich@shuttle /usr/ports/www/nginx]  make showconfig
===> The following configuration options are available for nginx-nopcre-1.8.0_3,2:
     DEBUG=on: Build with debugging support
     DEBUGLOG=on: Enable debug log (--with-debug)
     FILE_AIO=off: Enable file aio
     IPV6=off: IPv6 protocol support
     GOOGLE_PERFTOOLS=off: Enable google perftools module
     HTTP=on: Enable HTTP module
     HTTP_ADDITION=off: Enable http_addition module
     HTTP_AUTH_REQ=off: Enable http_auth_request module
     HTTP_CACHE=on: Enable http_cache module
     HTTP_DAV=off: Enable http_webdav module
     HTTP_FLV=off: Enable http_flv module
     HTTP_GEOIP=off: Enable http_geoip module
     HTTP_GZIP_STATIC=off: Enable http_gzip_static module
     HTTP_GUNZIP_FILTER=off: Enable http_gunzip_filter module
     HTTP_IMAGE_FILTER=off: Enable http_image_filter module
     HTTP_PERL=off: Enable http_perl module
     HTTP_RANDOM_INDEX=off: Enable http_random_index module
     HTTP_REALIP=off: Enable http_realip module
     HTTP_REWRITE=off: Enable http_rewrite module
     HTTP_SECURE_LINK=off: Enable http_secure_link module
     HTTP_SSL=off: Enable http_ssl module
     HTTP_STATUS=off: Enable http_stub_status module
     HTTP_SUB=off: Enable http_sub module
     HTTP_XSLT=off: Enable http_xslt module
     MAIL=off: Enable IMAP4/POP3/SMTP proxy module
     MAIL_IMAP=off: Enable IMAP4 proxy module
     MAIL_POP3=off: Enable POP3 proxy module
     MAIL_SMTP=off: Enable SMTP proxy module
     MAIL_SSL=off: Enable mail_ssl module
     SPDY=off: Enable SPDY protocol support (SSL req.)
     THREADS=off: Enable threads support
     WWW=on: Enable html sample files
     AJP=off: 3rd party ajp module
     CACHE_PURGE=off: 3rd party cache_purge module
     CLOJURE=off: 3rd party clojure module
     CT=off: 3rd party cert_transparency module (SSL req.)
     ECHO=off: 3rd party echo module
     HEADERS_MORE=off: 3rd party headers_more module
     HTTP_ACCEPT_LANGUAGE=off: 3rd party accept_language module
     HTTP_ACCESSKEY=off: 3rd party http_accesskey module
     HTTP_AUTH_DIGEST=off: 3rd party http_authdigest module
     HTTP_AUTH_KRB5=off: 3rd party http_auth_gss module
     HTTP_AUTH_LDAP=off: 3rd party http_auth_ldap module
     HTTP_AUTH_PAM=off: 3rd party http_auth_pam module
     HTTP_DAV_EXT=off: 3rd party webdav_ext module
     HTTP_EVAL=off: 3rd party eval module
     HTTP_FANCYINDEX=off: 3rd party http_fancyindex module
     HTTP_FOOTER=off: 3rd party http_footer module
     HTTP_MOGILEFS=off: 3rd party mogilefs module
     HTTP_NOTICE=off: 3rd party notice module
     HTTP_PUSH=off: 3rd party push module
     HTTP_PUSH_STREAM=off: 3rd party push stream module
     HTTP_REDIS=off: 3rd party http_redis module
     HTTP_RESPONSE=off: 3rd party http_response module
     HTTP_SUBS_FILTER=off: 3rd party subs filter module
     HTTP_TARANTOOL=off: 3rd party tarantool upstream module
     HTTP_UPLOAD=off: 3rd party upload module
     HTTP_UPLOAD_PROGRESS=off: 3rd party uploadprogress module
     HTTP_UPSTREAM_FAIR=off: 3rd party upstream fair module
     HTTP_UPSTREAM_STICKY=off: 3rd party upstream sticky module
     HTTP_ZIP=off: 3rd party http_zip module
     ARRAYVAR=off: 3rd party array_var module
     DRIZZLE=off: 3rd party drizzlie module
     ENCRYPTSESSION=off: 3rd party encrypted_session module
     FORMINPUT=off: 3rd party form_input module
     GRIDFS=off: 3rd party gridfs module
     ICONV=off: 3rd party iconv module
     LET=off: 3rd party let module
     LUA=off: 3rd party lua module
     MEMC=off: 3rd party memc (memcached) module
     MODSECURITY=off: 3rd party mod_security module
     NAXSI=off: 3rd party naxsi module
     PASSENGER=on: 3rd party passenger module
     POSTGRES=off: 3rd party postgres module
     RDS_CSV=off: 3rd party rds_csv module
     RDS_JSON=off: 3rd party rds_json module
     REDIS2=off: 3rd party redis2 module
     RTMP=off: 3rd party rtmp module
     SET_MISC=off: 3rd party set_misc module
     SFLOW=off: 3rd party sflow module
     SHIBBOLETH=off: 3rd party shibboleth module
     SLOWFS_CACHE=off: 3rd party slowfs_cache module
     SMALL_LIGHT=off: 3rd party small_light module
     SRCACHE=off: 3rd party srcache module
     STATSD=off: 3rd party statsd module
     UDPLOG=off: 3rd party udplog (syslog) module
     XRID_HEADER=off: 3rd party x-rid header module
     XSS=off: 3rd party xss module
     VIDEO=off: Video module support
====> Video module support: you can only select none or one of them
     HTTP_MP4=off: Enable http_mp4 module
     HTTP_MP4_H264=off: 3rd party mp4/h264 module
===> Use 'make config' to modify these settings
BTW, "getme" is my personal alias for "sudo make install clean"

Code:
[Sun Dec 27 02:32:46 rich@shuttle /usr/ports/www/nginx]  getme
===>  Installing for nginx-nopcre-1.8.0_3,2
===>   nginx-nopcre-1.8.0_3,2 depends on file: /usr/local/bin/ruby21 - found
===>  Checking if nginx-nopcre already installed
===>   Registering installation for nginx-nopcre-1.8.0_3,2
Installing nginx-nopcre-1.8.0_3,2...
pkg-static: nginx-nopcre-1.8.0_3,2 conflicts with nginx-1.8.0_3,2 (installs files into the same place).  Problematic file: /usr/local/share/licenses/nginx-1.8.0_3,2/catalog.mk
*** Error code 70

Stop.
make[1]: stopped in /usr/ports/www/nginx
*** Error code 1

Stop.
make: stopped in /usr/ports/www/nginx
This config is basic. Ports updated.
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 7,297
Messages: 29,745

If you look closely it's using a different package name; nginx-nopcre. Which conflicts with a package called nginx. A pkg delete nginx should solve that.
 

Bemep

New Member


Messages: 3

Good day. I have a problem about the following.Have a system with FreeBSD 10.3 put all from ports. Built with Rails passenger, nginx compiled with passenger, nginx compiled with passenger. The application created on rails.
Start nginx
Code:
service nginx start
In the browser I see the following
Code:
There was an error while trying to load the gem 'uglifier'. (Bundler::GemRequireError)
  /usr/local/lib/ruby/gems/2.2/gems/bundler-1.11.2/lib/bundler/runtime.rb:80:in `rescue in block (2 levels) in require'
  /usr/local/lib/ruby/gems/2.2/gems/bundler-1.11.2/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
  /usr/local/lib/ruby/gems/2.2/gems/bundler-1.11.2/lib/bundler/runtime.rb:72:in `each'
  /usr/local/lib/ruby/gems/2.2/gems/bundler-1.11.2/lib/bundler/runtime.rb:72:in `block in require'
  /usr/local/lib/ruby/gems/2.2/gems/bundler-1.11.2/lib/bundler/runtime.rb:61:in `each'
  /usr/local/lib/ruby/gems/2.2/gems/bundler-1.11.2/lib/bundler/runtime.rb:61:in `require'
  /usr/local/lib/ruby/gems/2.2/gems/bundler-1.11.2/lib/bundler.rb:99:in `require'
  /www/testo/config/application.rb:7:in `<top (required)>'
  /www/testo/config/environment.rb:2:in `require'
  /www/testo/config/environment.rb:2:in `<top (required)>'
  config.ru:3:in `require'
  config.ru:3:in `block in <main>'
  /usr/local/lib/ruby/gems/2.2/gems/rack-1.6.4/lib/rack/builder.rb:55:in `instance_eval'
  /usr/local/lib/ruby/gems/2.2/gems/rack-1.6.4/lib/rack/builder.rb:55:in `initialize'
  config.ru:1:in `new'
  config.ru:1:in `<main>'
  /usr/local/lib/ruby/gems/2.2/gems/passenger-5.0.26/src/helper-scripts/rack-preloader.rb:110:in `eval'
  /usr/local/lib/ruby/gems/2.2/gems/passenger-5.0.26/src/helper-scripts/rack-preloader.rb:110:in `preload_app'
  /usr/local/lib/ruby/gems/2.2/gems/passenger-5.0.26/src/helper-scripts/rack-preloader.rb:156:in `<module:App>'
  /usr/local/lib/ruby/gems/2.2/gems/passenger-5.0.26/src/helper-scripts/rack-preloader.rb:30:in `<module:PhusionPassenger>'
  /usr/local/lib/ruby/gems/2.2/gems/passenger-5.0.26/src/helper-scripts/rack-preloader.rb:29:in `<main>'
Stop the service ...
In the consolewrite
Code:
nginx -c /usr/local/etc/nginx/nginx.conf
nginx starts and everything works, no errors

Tell me what to finish to rails+passenger+nginx has worked at start service nginx.
Thank you.
 
Last edited by a moderator:
Top