Commit b0863dc8 authored by Stan Hu's avatar Stan Hu

Merge branch 'revert-94438e0c' into 'master'

Revert "Merge branch 'pks-ci-use-gitaly-git' into 'master'"

See merge request gitlab-org/gitlab!72828
parents b5ba302e 11bdc4cf
......@@ -181,7 +181,6 @@ setup-test-env:
paths:
- config/secrets.yml
- tmp/tests/gitaly/_build/bin/
- tmp/tests/gitaly/_build/deps/git/install
- tmp/tests/gitaly/config.toml
- tmp/tests/gitaly/gitaly2.config.toml
- tmp/tests/gitaly/internal/
......
ee4b20cc318876c4b237e277fefd9d75186a085c
4f0a07ba39f14adacf7d482128a5de2bb84f0eac
......@@ -104,6 +104,9 @@ module Gitlab
socket_filename = options[:gitaly_socket] || "gitaly.socket"
prometheus_listen_addr = options[:prometheus_listen_addr]
git_bin_path = File.expand_path('../gitaly/_build/deps/git/install/bin/git')
git_bin_path = nil unless File.exist?(git_bin_path)
config = {
# Override the set gitaly_address since Praefect is in the loop
socket_path: File.join(gitaly_dir, socket_filename),
......@@ -113,8 +116,8 @@ module Gitlab
# sidekiq jobs, and concurrency will be low anyway in test.
git: {
catfile_cache_size: 5,
bin_path: File.expand_path(File.join(gitaly_dir, '_build', 'deps', 'git', 'install', 'bin', 'git'))
},
bin_path: git_bin_path
}.compact,
prometheus_listen_addr: prometheus_listen_addr
}.compact
......
......@@ -67,7 +67,7 @@ Usage: rake "gitlab:gitaly:install[/installation/dir,/storage/path]")
env["BUNDLE_DEPLOYMENT"] = 'false'
end
Gitlab::Popen.popen([make_cmd, 'all', 'git'], nil, env)
Gitlab::Popen.popen([make_cmd], nil, env)
end
end
end
......
......@@ -208,10 +208,10 @@ RSpec.describe BranchesFinder do
context 'by page_token only' do
let(:params) { { page_token: 'feature' } }
it 'raises an error' do
expect do
subject
end.to raise_error(Gitlab::Git::CommandError, '13:could not find page token.')
it 'returns nothing' do
result = subject
expect(result.count).to eq(0)
end
end
......
......@@ -98,7 +98,7 @@ module GitalySetup
end
def build_gitaly
system(env.merge({ 'GIT_VERSION' => nil }), 'make all git', chdir: tmp_tests_gitaly_dir) # rubocop:disable GitlabSecurity/SystemCommandInjection
system(env, 'make', chdir: tmp_tests_gitaly_dir) # rubocop:disable GitlabSecurity/SystemCommandInjection
end
def start_gitaly
......
......@@ -68,7 +68,7 @@ RSpec.describe 'gitlab:gitaly namespace rake task', :silence_stdout do
it 'calls gmake in the gitaly directory' do
expect(Gitlab::Popen).to receive(:popen).with(%w[which gmake]).and_return(['/usr/bin/gmake', 0])
expect(Gitlab::Popen).to receive(:popen).with(%w[gmake all git], nil, { "BUNDLE_GEMFILE" => nil, "RUBYOPT" => nil }).and_return(true)
expect(Gitlab::Popen).to receive(:popen).with(%w[gmake], nil, { "BUNDLE_GEMFILE" => nil, "RUBYOPT" => nil }).and_return(true)
subject
end
......@@ -81,13 +81,13 @@ RSpec.describe 'gitlab:gitaly namespace rake task', :silence_stdout do
end
it 'calls make in the gitaly directory' do
expect(Gitlab::Popen).to receive(:popen).with(%w[make all git], nil, { "BUNDLE_GEMFILE" => nil, "RUBYOPT" => nil }).and_return(true)
expect(Gitlab::Popen).to receive(:popen).with(%w[make], nil, { "BUNDLE_GEMFILE" => nil, "RUBYOPT" => nil }).and_return(true)
subject
end
context 'when Rails.env is test' do
let(:command) { %w[make all git] }
let(:command) { %w[make] }
before do
stub_rails_env('test')
......
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