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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
718fe268
Commit
718fe268
authored
May 24, 2016
by
Kamil Trzcinski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improve after review
parent
12bd7810
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
lib/backup/manager.rb
lib/backup/manager.rb
+5
-5
No files found.
lib/backup/manager.rb
View file @
718fe268
module
Backup
module
Backup
class
Manager
class
Manager
ARCHIVES_TO_BACKUP
=
%w
{uploads builds artifacts lfs registry}
ARCHIVES_TO_BACKUP
=
%w
[uploads builds artifacts lfs registry]
FOLDERS_TO_BACKUP
=
%w
{repositories db}
FOLDERS_TO_BACKUP
=
%w
[repositories db]
def
pack
def
pack
# Make sure there is a connection
# Make sure there is a connection
...
@@ -150,7 +150,7 @@ module Backup
...
@@ -150,7 +150,7 @@ module Backup
end
end
def
skipped?
(
item
)
def
skipped?
(
item
)
settings
[
:skipped
]
&&
settings
[
:skipped
].
include?
(
item
)
settings
[
:skipped
]
&&
settings
[
:skipped
].
include?
(
item
)
||
disabled_features
.
include?
(
item
)
end
end
private
private
...
@@ -160,11 +160,11 @@ module Backup
...
@@ -160,11 +160,11 @@ module Backup
end
end
def
archives_to_backup
def
archives_to_backup
(
ARCHIVES_TO_BACKUP
-
disabled_features
)
.
map
{
|
name
|
(
name
+
".tar.gz"
)
unless
skipped?
(
name
)
}.
compact
ARCHIVES_TO_BACKUP
.
map
{
|
name
|
(
name
+
".tar.gz"
)
unless
skipped?
(
name
)
}.
compact
end
end
def
folders_to_backup
def
folders_to_backup
(
FOLDERS_TO_BACKUP
-
disabled_features
)
.
reject
{
|
name
|
skipped?
(
name
)
}
FOLDERS_TO_BACKUP
.
reject
{
|
name
|
skipped?
(
name
)
}
end
end
def
disabled_features
def
disabled_features
...
...
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