Skip to content
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

Cannot fork in jruby -> cannot daemonize -> handle gracefully #78

Merged
merged 1 commit into from May 23, 2013

Conversation

@bf4
Copy link
Contributor

@bf4 bf4 commented May 16, 2013

When trying to daemonize the standalone in JRuby, print to stderr and exit 1 as we cannot fork

I did try spoon e.g. https://gist.github.com/ik5/448884/raw/2d945080143a2682dc6ff1862013217265262f8e/daemon.rb but not https://github.com/nicobrevin/jruby-jsvc

@FooBarWidget
Copy link
Member

@FooBarWidget FooBarWidget commented May 22, 2013

Instead of explicitly checking for JRuby, you should use PlatformInfo.ruby_supports_fork? (located in phusion_passenger/platform_info/ruby.rb).

Also, could you sign the Contributor Agreement? We require this before we can accept a patch.

When trying to daemonize the standalone on a platform that
does not support fork, print to stderr and exit 1
@bf4
Copy link
Contributor Author

@bf4 bf4 commented May 22, 2013

Done and done

FooBarWidget added a commit that referenced this pull request May 23, 2013
Cannot fork in jruby -> cannot daemonize -> handle gracefully
@FooBarWidget FooBarWidget merged commit 8e41bde into phusion:master May 23, 2013
1 check passed
1 check passed
default The Travis CI build passed
Details
@FooBarWidget
Copy link
Member

@FooBarWidget FooBarWidget commented May 23, 2013

Alright, I've merged your changes, thanks for contributing. I've also fixed the indenting. You were using spaces but our codebase uses tabs.

@bf4
Copy link
Contributor Author

@bf4 bf4 commented May 23, 2013

ah, I was wondering why it was off

On Thu, May 23, 2013 at 8:33 AM, Hongli Lai notifications@github.comwrote:

Alright, I've merged your changes, thanks for contributing. I've also
fixed the indenting. You were using spaces but our codebase uses tabs.


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

@bf4 bf4 deleted the bf4:jruby-no-fork branch Dec 27, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants