-
Notifications
You must be signed in to change notification settings - Fork 249
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
Incorrect volume mapping in docker run for engines #1023
Comments
Hi @viddagrava, I think it is possible that we might be having a mismatch when passing a CODECLIMATE_CODE env var that is different from cd /builds/<workspace>/<project> && CODECLIMATE_DOCKER=1 CODECLIMATE_DEBUG=1 /usr/src/app/bin/codeclimate analyze |
Hey @filipesperandio, Thanks a lot for your fast reply, I already tried it, and unfortunately it does not help. Same error and with my very little understanding I don't think the |
@filipesperandio looks like the reason and workaround you gave is not working. Must be something else. |
I'm facing the same issue regarding gitlab ci, any news so far? |
Ugh, not so fast follow up, sorry. Do you all still see the same errors? Even if you drop the CODECLIMATE_CODE env var in favor of doing a |
Any news for this? |
commands I invoked: issue: logs: I, [2023-12-16T01:42:11.488330 #105] INFO -- : finished engine structure error: (CC::CLI::Analyze::EngineFailure) engine structure failed with status 1 and stderr 12 Parser process id: 12 codeclimate-parser socket not present waiting 1s... /home/app/.rubies/ruby-3.1.4/lib/ruby/gems/3.1.0/gems/bundler-1.16.4/lib/bundler/shared_helpers.rb:29: warning: Pathname#untaint is deprecated and will be removed in Ruby 3.2. /home/app/.rubies/ruby-3.1.4/lib/ruby/gems/3.1.0/gems/bundler-1.16.4/lib/bundler/shared_helpers.rb:118: warning: Pathname#untaint is deprecated and will be removed in Ruby 3.2. /home/app/.rubies/ruby-3.1.4/lib/ruby/gems/3.1.0/gems/bundler-1.16.4/lib/bundler/shared_helpers.rb:118: warning: Pathname#untaint is deprecated and will be removed in Ruby 3.2. /home/app/.rubies/ruby-3.1.4/lib/ruby/gems/3.1.0/gems/bundler-1.16.4/lib/bundler/shared_helpers.rb:35: warning: Pathname#untaint is deprecated and will be removed in Ruby 3.2. /home/app/.rubies/ruby-3.1.4/lib/ruby/gems/3.1.0/gems/bundler-1.16.4/lib/bundler/shared_helpers.rb:35: warning: Pathname#untaint is deprecated and will be removed in Ruby 3.2. /home/app/.rubies/ruby-3.1.4/lib/ruby/gems/3.1.0/gems/bundler-1.16.4/lib/bundler/shared_helpers.rb:44: warning: Pathname#untaint is deprecated and will be removed in Ruby 3.2. /home/app/.rubies/ruby-3.1.4/lib/ruby/gems/3.1.0/gems/bundler-1.16.4/lib/bundler/shared_helpers.rb:118: warning: Pathname#untaint is deprecated and will be removed in Ruby 3.2. bin/structure:21:in read': Is a directory @ io_fread - /config.json (Errno::EISDIR) from bin/structure:21:in '... /usr/src/app/lib/cc/analyzer/raising_container_listener.rb:23:in finished' /usr/src/app/lib/cc/analyzer/composite_container_listener.rb:13:in block in finished'/usr/src/app/lib/cc/analyzer/composite_container_listener.rb:13:in each' /usr/src/app/lib/cc/analyzer/composite_container_listener.rb:13:in finished'/usr/src/app/lib/cc/analyzer/bridge.rb:52:in block (2 levels) in run' /usr/src/app/lib/cc/analyzer/formatters/plain_text_formatter.rb:63:in with_spinner'/usr/src/app/lib/cc/analyzer/formatters/plain_text_formatter.rb:41:in block in engine_running' /usr/src/app/lib/cc/analyzer/formatters/formatter.rb:31:in engine_running'/usr/src/app/lib/cc/analyzer/formatters/plain_text_formatter.rb:40:in engine_running' /usr/src/app/lib/cc/analyzer/bridge.rb:37:in block in run'/usr/src/app/lib/cc/analyzer/bridge.rb:34:in each' /usr/src/app/lib/cc/analyzer/bridge.rb:34:in run'/usr/src/app/lib/cc/cli/analyze.rb:36:in run' /usr/src/app/lib/cc/cli/command.rb:73:in execute'/usr/src/app/lib/cc/cli/runner.rb:25:in run' /usr/src/app/lib/cc/cli/runner.rb:9:in run'/usr/src/app/bin/codeclimate:12:in `' |
Hey guys,
thanks a lot for the good work. Nonetheless, I believe there's an issue with how the wrapper runs the engines.
I am trying to run the container in a gitlab pipeline with the following:
and this is the output I get:
why is the tmp folder path mapped to config.json (
/tmp/cc/18cfcc2e-704c-4334-9912-7525b306d2fc:/config.json:ro
)?I guess the problem lies here (codeclimate/lib/cc/analyzer/engine.rb: line 76-92):
especially line 85:
"--volume", "#{config_file.host_path}:/config.json:ro",
Thanks in advance.
David
The text was updated successfully, but these errors were encountered: