I'm not a user of rbenv, but when I still used ruby and RVM I had to load
rvm manually in startup scripts. RVM even had a function to create shims
which did this for you.

This is necessary, because RVM (and probably RBenv) are only loaded in a
log in shell through its bash/zsh/whatever-rc files. The various
init-systems do not use login-shells but start their stuff in very minimal
environments, therefore you have to do lot of the setup on your own.

Ben Edwards <lo...@funkytwig.com> schrieb am Mi., 13. Sep. 2017 um
16:16 Uhr:

> User in unicorn.rb is ben.  When I am logged in as ben I can type unicorn
> and it finds/runs it.  Ime using rbenv.  I did have this working and
> reinstlled rbenv localy in the user.  sould of mentioned ths buy it was a
> 2PAM post just before I caled it a day.  Will post config files later when
> I get home.
>
>
> On Wednesday, September 13, 2017 at 8:30:23 AM UTC+1, Norbert Melzer wrote:
>
>> Have you installed it for the correct user? Or locally to your current?
>>
>> On Mi., 13. Sep. 2017, 03:12 Ben Edwards <lo...@funkytwig.com> wrote:
>>
> Logfile is:
>>>
>>> ben@whatnow:~/eventpuddle/eventpuddle/rails/eventpuddle$ systemctl
>>> status unicorn_eventpuddle.service
>>> ● unicorn_eventpuddle.service - LSB: starts the unicorn app server
>>>    Loaded: loaded (/etc/init.d/unicorn_eventpuddle; bad; vendor preset:
>>> enabled)
>>>    Active: failed (Result: exit-code) since Wed 2017-09-13 02:03:19 BST;
>>> 3min 2s ago
>>>      Docs: man:systemd-sysv-generator(8)
>>>   Process: 5386 ExecStart=/etc/init.d/unicorn_eventpuddle start
>>> (code=exited, status=127)
>>>
>>> Sep 13 02:03:19 whatnow unicorn_eventpuddle[5386]: Starting eventpuddle
>>> Sep 13 02:03:19 whatnow su[5388]: Successful su for ben by root
>>> Sep 13 02:03:19 whatnow su[5388]: + ??? root:ben
>>> Sep 13 02:03:19 whatnow su[5388]: pam_unix(su:session): session opened
>>> for user ben by (uid=0)
>>> *Sep 13 02:03:19 whatnow unicorn_eventpuddle[5386]: bundler: command not
>>> found: unicorn*
>>> Sep 13 02:03:19 whatnow unicorn_eventpuddle[5386]: Install missing gem
>>> executables with `bundle install`
>>> Sep 13 02:03:19 whatnow systemd[1]: unicorn_eventpuddle.service: Control
>>> process exited, code=exited status=127
>>> Sep 13 02:03:19 whatnow systemd[1]: Failed to start LSB: starts the
>>> unicorn app server.
>>> Sep 13 02:03:19 whatnow systemd[1]: unicorn_eventpuddle.service: Unit
>>> entered failed state.
>>> Sep 13 02:03:19 whatnow systemd[1]: unicorn_eventpuddle.service: Failed
>>> with result 'exit-code'.
>>> ben@whatnow:~/eventpuddle/eventpuddle/rails/eventpuddle$
>>>
>>> It says unicorn not found but it is. I have it in my Gemfile and I also
>>> installed it with 'gem install unicorn'.
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Ruby on Rails: Talk" group.
>>>
>> To unsubscribe from this group and stop receiving emails from it, send an
>>> email to rubyonrails-ta...@googlegroups.com.
>>> To post to this group, send email to rubyonra...@googlegroups.com.
>>
>>
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/rubyonrails-talk/fcd2b2dc-7c21-4ddd-84ae-2e800446b603%40googlegroups.com
>>> <https://groups.google.com/d/msgid/rubyonrails-talk/fcd2b2dc-7c21-4ddd-84ae-2e800446b603%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
> You received this message because you are subscribed to the Google Groups
> "Ruby on Rails: Talk" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rubyonrails-talk+unsubscr...@googlegroups.com.
> To post to this group, send email to rubyonrails-talk@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/rubyonrails-talk/3abc15ba-cf73-4aab-b601-75fd4844761c%40googlegroups.com
> <https://groups.google.com/d/msgid/rubyonrails-talk/3abc15ba-cf73-4aab-b601-75fd4844761c%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rubyonrails-talk+unsubscr...@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rubyonrails-talk/CA%2BbCVsuP_gU9Hg0upWm1gXa%2B-aPv0XnRTfZ6dpaD2au0BTA6RQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to