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
Tatuya Kamada
gitlab-ce
Commits
732a821d
Commit
732a821d
authored
Dec 15, 2015
by
Kamil Trzcinski
Committed by
James Edwards-Jones
Jan 31, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix specs
parent
120f9aba
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
2 deletions
+8
-2
app/workers/pages_worker.rb
app/workers/pages_worker.rb
+2
-1
config/sidekiq_queues.yml
config/sidekiq_queues.yml
+1
-0
lib/backup/manager.rb
lib/backup/manager.rb
+1
-1
spec/services/update_pages_service_spec.rb
spec/services/update_pages_service_spec.rb
+4
-0
No files found.
app/workers/pages_worker.rb
View file @
732a821d
...
@@ -34,7 +34,8 @@ class PagesWorker
...
@@ -34,7 +34,8 @@ class PagesWorker
# We manually extract the archive and limit the archive size with dd
# We manually extract the archive and limit the archive size with dd
results
=
Open3
.
pipeline
(
%W(gunzip -c
#{
artifacts
}
)
,
results
=
Open3
.
pipeline
(
%W(gunzip -c
#{
artifacts
}
)
,
%W(dd bs=
#{
BLOCK_SIZE
}
count=
#{
blocks
}
)
,
%W(dd bs=
#{
BLOCK_SIZE
}
count=
#{
blocks
}
)
,
%W(tar -x -C
#{
temp_path
}
public/)
)
%W(tar -x -C
#{
temp_path
}
public/)
,
err:
'/dev/null'
)
return
unless
results
.
compact
.
all?
(
&
:success?
)
return
unless
results
.
compact
.
all?
(
&
:success?
)
# Check if we did extract public directory
# Check if we did extract public directory
...
...
config/sidekiq_queues.yml
View file @
732a821d
...
@@ -50,3 +50,4 @@
...
@@ -50,3 +50,4 @@
- [reactive_caching, 1]
- [reactive_caching, 1]
- [cronjob, 1]
- [cronjob, 1]
- [default, 1]
- [default, 1]
- [pages, 1]
lib/backup/manager.rb
View file @
732a821d
module
Backup
module
Backup
class
Manager
class
Manager
ARCHIVES_TO_BACKUP
=
%w[uploads builds artifacts lfs registry]
ARCHIVES_TO_BACKUP
=
%w[uploads builds artifacts
pages
lfs registry]
FOLDERS_TO_BACKUP
=
%w[repositories db]
FOLDERS_TO_BACKUP
=
%w[repositories db]
FILE_NAME_SUFFIX
=
'_gitlab_backup.tar'
FILE_NAME_SUFFIX
=
'_gitlab_backup.tar'
...
...
spec/services/update_pages_service_spec.rb
View file @
732a821d
...
@@ -5,6 +5,10 @@ describe UpdatePagesService, services: true do
...
@@ -5,6 +5,10 @@ describe UpdatePagesService, services: true do
let
(
:data
)
{
Gitlab
::
BuildDataBuilder
.
build
(
build
)
}
let
(
:data
)
{
Gitlab
::
BuildDataBuilder
.
build
(
build
)
}
let
(
:service
)
{
UpdatePagesService
.
new
(
data
)
}
let
(
:service
)
{
UpdatePagesService
.
new
(
data
)
}
before
do
allow
(
Gitlab
.
config
.
pages
).
to
receive
(
:enabled
).
and_return
(
true
)
end
context
'execute asynchronously for pages job'
do
context
'execute asynchronously for pages job'
do
before
{
build
.
name
=
'pages'
}
before
{
build
.
name
=
'pages'
}
...
...
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