ruby on rails - unable to restart my unicorn server (getting "Argument list too long" error) -


i'm using rails 5 ruby 2.4 in ubuntu 14.04 environment. i'm having trouble figuring out how configure unicorn starts rails server. have in /etc/default/unicorn file

# change paramentres below appropriate values , set configured yes. configured=yes  # default timeout until child process killed during server upgrade, # has *no* relation option "timeout" in server's config.rb. timeout=60  # path web application, sh'ld set in server's config.rb, # option "working_directory". rack's config.ru located here. app_root=/home/rails/myproject  # server's config.rb, it's not rack's config.ru config_rb=/etc/unicorn.conf  # store pid, sh'ld set in server's config.rb, option "pid". pid=/var/run/unicorn.pid rails_env="production" unicorn_opts="-d -c $config_rb -e $rails_env"  export gem_home=/home/rails/.gem export gem_path=$gem_home/ruby/2.4.0 path=$gem_home/wrappers:/usr/local/sbin:/usr/bin:/bin:/sbin:/usr/local/rvm/bin daemon=$gem_path/bin/unicorn  # generate running `rake -f /home/rails/rails_project/rakefile secret` export secret_key_base=02913376d024bde25bcd5f46b8a474e928ac5a6a44217cffe62692521abc9fdb4e471c748fb6ff6d2bf18bfaab87fc834ad32.45ca0bb1c0176028b5b61efc776 export app_database_password=aewco2ljbq 

but when go restart unicorn, belwo error

myuser@myproject:~$ sudo service unicorn restart  * restarting unicorn web server unicorn  /home/rails/.gem/wrappers/ruby: line 7: /home/rails/.gem/wrappers/ruby: argument list long /home/rails/.gem/wrappers/ruby: line 7: /home/rails/.gem/wrappers/ruby: success 

how point unicorn right ruby executable or there other configuraiton i'm missing?


Comments