pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/57382: ruby-redmine50: Add bundle exec in rc.d script



>Number:         57382
>Category:       pkg
>Synopsis:       ruby-redmine50: Add bundle exec in rc.d script
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Apr 27 20:50:01 +0000 2023
>Originator:     Frédéric Fauberteau
>Release:        Darwin 22.4.0
>Organization:
>Environment:
System: NetBSD mollari.NetBSD.org 9.2_STABLE NetBSD 9.2_STABLE (amd64-DOMU_SERVER) #1: Fri Dec 10 07:06:09 UTC 2021 spz%franklin.NetBSD.org@localhost:/home/netbsd/9/amd64/obj/sys/arch/amd64/compile/amd64-DOMU_SERVER amd64
System: Darwin arbiter.local 22.4.0 Darwin Kernel Version 22.4.0: Mon Mar  6 21:00:41 PST 2023; root:xnu-8796.101.5~3/RELEASE_ARM64_T8103 arm64
Architecture: aarch64
>Description:
When I start redmine, I get the following error in unicorn.log:
| /usr/pkg/lib/ruby/3.1.0/bundler/runtime.rb:308:in `check_for_activated_spec!': You have already activated rack 3.0.7, but your Gemfile requires rack 2.2.6.4. Prepending `bundle exec` to your command may solve this. (Gem::LoadError)
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/runtime.rb:25:in `block in setup'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/spec_set.rb:155:in `each'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/spec_set.rb:155:in `each'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/runtime.rb:24:in `map'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/runtime.rb:24:in `setup'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler.rb:161:in `setup'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/setup.rb:20:in `block in <top (required)>'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/ui/shell.rb:136:in `with_level'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/ui/shell.rb:88:in `silence'
| 	from /usr/pkg/lib/ruby/3.1.0/bundler/setup.rb:20:in `<top (required)>'
| 	from <internal:/usr/pkg/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
| 	from <internal:/usr/pkg/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
| 	from /usr/pkg/share/ruby31-redmine50/config/boot.rb:6:in `<top (required)>'
| 	from <internal:/usr/pkg/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
| 	from <internal:/usr/pkg/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
| 	from /usr/pkg/share/ruby31-redmine50/config/application.rb:3:in `<top (required)>'
| 	from <internal:/usr/pkg/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
| 	from <internal:/usr/pkg/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
| 	from /usr/pkg/share/ruby31-redmine50/config/environment.rb:4:in `<top (required)>'
| 	from <internal:/usr/pkg/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
| 	from <internal:/usr/pkg/lib/ruby/3.1.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
| 	from config.ru:4:in `block in <main>'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/rack-3.0.7/lib/rack/builder.rb:118:in `instance_eval'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/rack-3.0.7/lib/rack/builder.rb:118:in `initialize'
| 	from config.ru:1:in `new'
| 	from config.ru:1:in `<main>'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/unicorn-6.1.0/lib/unicorn.rb:54:in `eval'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/unicorn-6.1.0/lib/unicorn.rb:54:in `block in builder'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/unicorn-6.1.0/lib/unicorn/http_server.rb:821:in `build_app!'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/unicorn-6.1.0/lib/unicorn/http_server.rb:689:in `init_worker_process'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/unicorn-6.1.0/lib/unicorn/http_server.rb:721:in `worker_loop'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/unicorn-6.1.0/lib/unicorn/http_server.rb:547:in `spawn_missing_workers'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/unicorn-6.1.0/lib/unicorn/http_server.rb:143:in `start'
| 	from /usr/pkg/lib/ruby/gems/3.1.0/gems/unicorn-6.1.0/bin/unicorn:128:in `<top (required)>'
| 	from /usr/pkg/bin/unicorn31:25:in `load'
| 	from /usr/pkg/bin/unicorn31:25:in `<main>'

I get the same eror on NetBSD 9.2
>How-To-Repeat:
service redmine50_unicorn31 start
cat /usr/pkg/share/ruby31-redmine50/unicorn.log
>Fix:
--- files/redmine50_unicorn.sh	19 Apr 2023 15:43:17 -0000	1.3
+++ files/redmine50_unicorn.sh	27 Apr 2023 20:32:58 -0000
@@ -19,7 +19,7 @@
 redmine50_unicorn_start()
 {
 	cd @PREFIX@/@RM_DIR@
-	@PREFIX@/bin/unicorn@RUBY_SUFFIX@ \
+	@PREFIX@/bin/bundle@RUBY_SUFFIX@ exec @PREFIX@/bin/unicorn@RUBY_SUFFIX@ \
 		-c @PREFIX@/@RM_DIR@/config/unicorn.rb \
 		-E production -D
 }



Home | Main Index | Thread Index | Old Index