Commit 5e33cf5bd24d599bf54375abfa999dd838cd8b28
1 parent
7e47c4af
Exists in
master
and in
2 other branches
Revert "Merge branch 'remove_rsync' into 'master'"
The built-in sync command of omnibus-ruby 3.2.1 was giving us trouble. This reverts commit 8da230e73d0f10ff9db3660ecaeb8cff98276824, reversing changes made to 9c8b7f30784fd008cd536fab75b5000103a567fb.
Showing
4 changed files
with
10 additions
and
5 deletions
Show diff stats
config/software/gitlab-cookbooks.rb
@@ -18,11 +18,13 @@ | @@ -18,11 +18,13 @@ | ||
18 | 18 | ||
19 | name "gitlab-cookbooks" | 19 | name "gitlab-cookbooks" |
20 | 20 | ||
21 | +dependency "rsync" | ||
22 | + | ||
21 | always_build true | 23 | always_build true |
22 | 24 | ||
23 | source :path => File.expand_path("files/gitlab-cookbooks", Config.project_root) | 25 | source :path => File.expand_path("files/gitlab-cookbooks", Config.project_root) |
24 | 26 | ||
25 | build do | 27 | build do |
26 | command "mkdir -p #{install_dir}/embedded/cookbooks" | 28 | command "mkdir -p #{install_dir}/embedded/cookbooks" |
27 | - sync project_dir, "#{install_dir}/embedded/cookbooks/" | 29 | + command "#{install_dir}/embedded/bin/rsync --delete -a ./ #{install_dir}/embedded/cookbooks/" |
28 | end | 30 | end |
config/software/gitlab-ctl.rb
@@ -18,6 +18,7 @@ | @@ -18,6 +18,7 @@ | ||
18 | 18 | ||
19 | name "gitlab-ctl" | 19 | name "gitlab-ctl" |
20 | 20 | ||
21 | +dependency "rsync" | ||
21 | dependency "omnibus-ctl" | 22 | dependency "omnibus-ctl" |
22 | 23 | ||
23 | source :path => File.expand_path("files/gitlab-ctl-commands", Config.project_root) | 24 | source :path => File.expand_path("files/gitlab-ctl-commands", Config.project_root) |
@@ -64,5 +65,5 @@ done | @@ -64,5 +65,5 @@ done | ||
64 | command "chmod 755 #{install_dir}/bin/gitlab-ctl" | 65 | command "chmod 755 #{install_dir}/bin/gitlab-ctl" |
65 | 66 | ||
66 | # additional omnibus-ctl commands | 67 | # additional omnibus-ctl commands |
67 | - sync project_dir, "#{install_dir}/embedded/service/omnibus-ctl/" | 68 | + command "#{install_dir}/embedded/bin/rsync -a ./ #{install_dir}/embedded/service/omnibus-ctl/" |
68 | end | 69 | end |
config/software/gitlab-rails.rb
@@ -26,6 +26,7 @@ dependency "bundler" | @@ -26,6 +26,7 @@ dependency "bundler" | ||
26 | dependency "libxml2" | 26 | dependency "libxml2" |
27 | dependency "libxslt" | 27 | dependency "libxslt" |
28 | dependency "curl" | 28 | dependency "curl" |
29 | +dependency "rsync" | ||
29 | dependency "libicu" | 30 | dependency "libicu" |
30 | dependency "postgresql" | 31 | dependency "postgresql" |
31 | dependency "python-docutils" | 32 | dependency "python-docutils" |
@@ -38,7 +39,7 @@ build do | @@ -38,7 +39,7 @@ build do | ||
38 | env = with_standard_compiler_flags(with_embedded_path) | 39 | env = with_standard_compiler_flags(with_embedded_path) |
39 | 40 | ||
40 | # GitLab assumes it can extract the Git revision of the currently version | 41 | # GitLab assumes it can extract the Git revision of the currently version |
41 | - # from the Git repo the code lives in at boot. Because of our sync later on, | 42 | + # from the Git repo the code lives in at boot. Because of our rsync later on, |
42 | # this assumption does not hold. The sed command below patches the GitLab | 43 | # this assumption does not hold. The sed command below patches the GitLab |
43 | # source code to include the Git revision of the code included in the omnibus | 44 | # source code to include the Git revision of the code included in the omnibus |
44 | # build. | 45 | # build. |
@@ -83,7 +84,7 @@ build do | @@ -83,7 +84,7 @@ build do | ||
83 | command "cp db/schema.rb db/schema.rb.bundled" | 84 | command "cp db/schema.rb db/schema.rb.bundled" |
84 | 85 | ||
85 | command "mkdir -p #{install_dir}/embedded/service/gitlab-rails" | 86 | command "mkdir -p #{install_dir}/embedded/service/gitlab-rails" |
86 | - sync project_dir, "#{install_dir}/embedded/service/gitlab-rails/", exclude: %w{.git .gitignore} | 87 | + command "#{install_dir}/embedded/bin/rsync -a --delete --exclude=.git/*** --exclude=.gitignore ./ #{install_dir}/embedded/service/gitlab-rails/" |
87 | 88 | ||
88 | # Create a wrapper for the rake tasks of the Rails app | 89 | # Create a wrapper for the rake tasks of the Rails app |
89 | erb :dest => "#{install_dir}/bin/gitlab-rake", | 90 | erb :dest => "#{install_dir}/bin/gitlab-rake", |
config/software/gitlab-shell.rb
@@ -20,12 +20,13 @@ name "gitlab-shell" | @@ -20,12 +20,13 @@ name "gitlab-shell" | ||
20 | default_version "91753e937e729c0fedc9a5dd7ae52b85436b4971" # 1.9.7 | 20 | default_version "91753e937e729c0fedc9a5dd7ae52b85436b4971" # 1.9.7 |
21 | 21 | ||
22 | dependency "ruby" | 22 | dependency "ruby" |
23 | +dependency "rsync" | ||
23 | 24 | ||
24 | source :git => "https://gitlab.com/gitlab-org/gitlab-shell.git" | 25 | source :git => "https://gitlab.com/gitlab-org/gitlab-shell.git" |
25 | 26 | ||
26 | build do | 27 | build do |
27 | command "mkdir -p #{install_dir}/embedded/service/gitlab-shell" | 28 | command "mkdir -p #{install_dir}/embedded/service/gitlab-shell" |
28 | - sync project_dir, "#{install_dir}/embedded/service/gitlab-shell/", exclude: %{.git .gitignore} | 29 | + command "#{install_dir}/embedded/bin/rsync -a --delete --exclude=.git/*** --exclude=.gitignore ./ #{install_dir}/embedded/service/gitlab-shell/" |
29 | block do | 30 | block do |
30 | env_shebang = "#!/usr/bin/env ruby" | 31 | env_shebang = "#!/usr/bin/env ruby" |
31 | `grep -r -l '^#{env_shebang}' #{project_dir}`.split("\n").each do |ruby_script| | 32 | `grep -r -l '^#{env_shebang}' #{project_dir}`.split("\n").each do |ruby_script| |