Commit ccae2a7e authored by Bob Van Landuyt's avatar Bob Van Landuyt

Merge branch 'cl-pass-projectpath-to-gei' into 'master'

Pass project full path to indexer

See merge request gitlab-org/gitlab!47479
parents 43ddc964 8a93590e
...@@ -73,9 +73,9 @@ module Gitlab ...@@ -73,9 +73,9 @@ module Gitlab
command = command =
if index_wiki? if index_wiki?
[path_to_indexer, "--blob-type=wiki_blob", "--skip-commits", project.id.to_s, repository_path] [path_to_indexer, "--blob-type=wiki_blob", "--skip-commits", "--project-path=#{project.full_path}", project.id.to_s, repository_path]
else else
[path_to_indexer, project.id.to_s, repository_path] [path_to_indexer, "--project-path=#{project.full_path}", project.id.to_s, repository_path]
end end
output, status = Gitlab::Popen.popen(command, nil, vars) output, status = Gitlab::Popen.popen(command, nil, vars)
......
...@@ -92,6 +92,7 @@ RSpec.describe Gitlab::Elastic::Indexer do ...@@ -92,6 +92,7 @@ RSpec.describe Gitlab::Elastic::Indexer do
expect_popen.with( expect_popen.with(
[ [
TestEnv.indexer_bin_path, TestEnv.indexer_bin_path,
"--project-path=#{project.full_path}",
project.id.to_s, project.id.to_s,
"#{project.repository.disk_path}.git" "#{project.repository.disk_path}.git"
], ],
...@@ -214,6 +215,7 @@ RSpec.describe Gitlab::Elastic::Indexer do ...@@ -214,6 +215,7 @@ RSpec.describe Gitlab::Elastic::Indexer do
TestEnv.indexer_bin_path, TestEnv.indexer_bin_path,
'--blob-type=wiki_blob', '--blob-type=wiki_blob',
'--skip-commits', '--skip-commits',
"--project-path=#{project.full_path}",
project.id.to_s, project.id.to_s,
"#{project.wiki.repository.disk_path}.git" "#{project.wiki.repository.disk_path}.git"
], ],
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment