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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
0d0e6ba0
Commit
0d0e6ba0
authored
Feb 13, 2018
by
Micaël Bergeron
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix the background_upload configuration being ignored
parent
7afd29db
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
16 deletions
+14
-16
changelogs/unreleased-ee/4915-background-upload-option-is-not-effective.yml
...sed-ee/4915-background-upload-option-is-not-effective.yml
+5
-0
config/initializers/1_settings.rb
config/initializers/1_settings.rb
+9
-16
No files found.
changelogs/unreleased-ee/4915-background-upload-option-is-not-effective.yml
0 → 100644
View file @
0d0e6ba0
---
title
:
Fix the background_upload configuration being ignored.
merge_request
:
4507
author
:
type
:
fixed
config/initializers/1_settings.rb
View file @
0d0e6ba0
...
@@ -348,9 +348,9 @@ Settings.artifacts['storage_path'] = Settings.absolute(Settings.artifacts.values
...
@@ -348,9 +348,9 @@ Settings.artifacts['storage_path'] = Settings.absolute(Settings.artifacts.values
Settings
.
artifacts
[
'path'
]
=
Settings
.
artifacts
[
'storage_path'
]
Settings
.
artifacts
[
'path'
]
=
Settings
.
artifacts
[
'storage_path'
]
Settings
.
artifacts
[
'max_size'
]
||=
100
# in megabytes
Settings
.
artifacts
[
'max_size'
]
||=
100
# in megabytes
Settings
.
artifacts
[
'object_store'
]
||=
Settingslogic
.
new
({})
Settings
.
artifacts
[
'object_store'
]
||=
Settingslogic
.
new
({})
Settings
.
artifacts
[
'object_store'
][
'enabled'
]
||=
false
Settings
.
artifacts
[
'object_store'
][
'enabled'
]
=
false
if
Settings
.
artifacts
[
'object_store'
][
'enabled'
].
nil?
Settings
.
artifacts
[
'object_store'
][
'remote_directory'
]
||=
nil
Settings
.
artifacts
[
'object_store'
][
'remote_directory'
]
||=
nil
Settings
.
artifacts
[
'object_store'
][
'background_upload'
]
||=
true
Settings
.
artifacts
[
'object_store'
][
'background_upload'
]
=
true
if
Settings
.
artifacts
[
'object_store'
][
'background_upload'
].
nil?
# Convert upload connection settings to use string keys, to make Fog happy
# Convert upload connection settings to use string keys, to make Fog happy
Settings
.
artifacts
[
'object_store'
][
'connection'
]
&
.
deep_stringify_keys!
Settings
.
artifacts
[
'object_store'
][
'connection'
]
&
.
deep_stringify_keys!
...
@@ -394,9 +394,9 @@ Settings['lfs'] ||= Settingslogic.new({})
...
@@ -394,9 +394,9 @@ Settings['lfs'] ||= Settingslogic.new({})
Settings
.
lfs
[
'enabled'
]
=
true
if
Settings
.
lfs
[
'enabled'
].
nil?
Settings
.
lfs
[
'enabled'
]
=
true
if
Settings
.
lfs
[
'enabled'
].
nil?
Settings
.
lfs
[
'storage_path'
]
=
Settings
.
absolute
(
Settings
.
lfs
[
'storage_path'
]
||
File
.
join
(
Settings
.
shared
[
'path'
],
"lfs-objects"
))
Settings
.
lfs
[
'storage_path'
]
=
Settings
.
absolute
(
Settings
.
lfs
[
'storage_path'
]
||
File
.
join
(
Settings
.
shared
[
'path'
],
"lfs-objects"
))
Settings
.
lfs
[
'object_store'
]
||=
Settingslogic
.
new
({})
Settings
.
lfs
[
'object_store'
]
||=
Settingslogic
.
new
({})
Settings
.
lfs
[
'object_store'
][
'enabled'
]
||=
false
Settings
.
lfs
[
'object_store'
][
'enabled'
]
=
false
if
Settings
.
lfs
[
'object_store'
][
'enabled'
].
nil?
Settings
.
lfs
[
'object_store'
][
'remote_directory'
]
||=
nil
Settings
.
lfs
[
'object_store'
][
'remote_directory'
]
||=
nil
Settings
.
lfs
[
'object_store'
][
'background_upload'
]
||=
true
Settings
.
lfs
[
'object_store'
][
'background_upload'
]
=
true
if
Settings
.
lfs
[
'object_store'
][
'background_upload'
].
nil?
# Convert upload connection settings to use string keys, to make Fog happy
# Convert upload connection settings to use string keys, to make Fog happy
Settings
.
lfs
[
'object_store'
][
'connection'
]
&
.
deep_stringify_keys!
Settings
.
lfs
[
'object_store'
][
'connection'
]
&
.
deep_stringify_keys!
...
@@ -407,19 +407,12 @@ Settings['uploads'] ||= Settingslogic.new({})
...
@@ -407,19 +407,12 @@ Settings['uploads'] ||= Settingslogic.new({})
Settings
.
uploads
[
'storage_path'
]
=
Settings
.
absolute
(
Settings
.
uploads
[
'storage_path'
]
||
'public'
)
Settings
.
uploads
[
'storage_path'
]
=
Settings
.
absolute
(
Settings
.
uploads
[
'storage_path'
]
||
'public'
)
Settings
.
uploads
[
'base_dir'
]
=
Settings
.
uploads
[
'base_dir'
]
||
'uploads/-/system'
Settings
.
uploads
[
'base_dir'
]
=
Settings
.
uploads
[
'base_dir'
]
||
'uploads/-/system'
Settings
.
uploads
[
'object_store'
]
||=
Settingslogic
.
new
({})
Settings
.
uploads
[
'object_store'
]
||=
Settingslogic
.
new
({})
Settings
.
uploads
[
'object_store'
][
'enabled'
]
||=
false
Settings
.
uploads
[
'object_store'
][
'enabled'
]
=
false
if
Settings
.
uploads
[
'object_store'
][
'enabled'
].
nil?
Settings
.
uploads
[
'object_store'
][
'remote_directory'
]
||=
'uploads'
Settings
.
uploads
[
'object_store'
][
'remote_directory'
]
||=
'uploads'
Settings
.
uploads
[
'object_store'
][
'background_upload'
]
||=
true
Settings
.
uploads
[
'object_store'
][
'background_upload'
]
=
true
if
Settings
.
uploads
[
'object_store'
][
'background_upload'
].
nil?
# Convert upload connection settings to use string keys, to make Fog happy
# Convert upload connection settings to use string keys, to make Fog happy
Settings
.
uploads
[
'object_store'
][
'connection'
]
&
.
deep_stringify_keys!
Settings
.
uploads
[
'object_store'
][
'connection'
]
&
.
deep_stringify_keys!
#
# Uploads
#
Settings
[
'uploads'
]
||=
Settingslogic
.
new
({})
Settings
.
uploads
[
'storage_path'
]
=
Settings
.
absolute
(
Settings
.
uploads
[
'storage_path'
]
||
'public'
)
Settings
.
uploads
[
'base_dir'
]
=
Settings
.
uploads
[
'base_dir'
]
||
'uploads/-/system'
#
#
# Mattermost
# Mattermost
#
#
...
...
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