Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
9c4f9677
Commit
9c4f9677
authored
May 23, 2018
by
Ahmad Hassan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Take restoring custom hooks and the skip flag out of scope
parent
80197bdc
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
4 deletions
+2
-4
lib/backup/repository.rb
lib/backup/repository.rb
+2
-4
No files found.
lib/backup/repository.rb
View file @
9c4f9677
...
...
@@ -70,8 +70,6 @@ module Backup
# TODO: Need to find a way to do this for gitaly
# Gitaly discussion issue: https://gitlab.com/gitlab-org/gitaly/issues/1194
return
if
Gitlab
::
GitalyClient
.
feature_enabled?
(
:backup_skip_prepare_directories
)
Gitlab
.
config
.
repositories
.
storages
.
each
do
|
name
,
repository_storage
|
path
=
repository_storage
.
legacy_disk_path
next
unless
File
.
exist?
(
path
)
...
...
@@ -92,7 +90,7 @@ module Backup
end
end
def
restore_custom_hooks
def
restore_custom_hooks
(
project
)
# TODO: Need to find a way to do this for gitaly
# Gitaly migration issue: https://gitlab.com/gitlab-org/gitaly/issues/1195
in_path
(
path_to_tars
(
project
))
do
|
dir
|
...
...
@@ -134,7 +132,7 @@ module Backup
progress
.
puts
"[Failed] restoring
#{
project
.
full_path
}
repository"
.
color
(
:red
)
end
restore_custom_hooks
unless
Gitlab
::
GitalyClient
.
feature_enabled?
(
:backup_skip_restore_custom_hooks
)
restore_custom_hooks
(
project
)
wiki
=
ProjectWiki
.
new
(
project
)
path_to_wiki_bundle
=
path_to_bundle
(
wiki
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment