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
5ffae25a
Commit
5ffae25a
authored
Jul 23, 2018
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add packages to config files [ci skip]
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
de2f836b
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
0 deletions
+40
-0
app/uploaders/packages/package_file_uploader.rb
app/uploaders/packages/package_file_uploader.rb
+2
-0
config/gitlab.yml.example
config/gitlab.yml.example
+20
-0
config/initializers/1_settings.rb
config/initializers/1_settings.rb
+18
-0
No files found.
app/uploaders/packages/package_file_uploader.rb
View file @
5ffae25a
...
...
@@ -2,5 +2,7 @@ class Packages::PackageFileUploader < GitlabUploader
extend
Workhorse
::
UploadPath
include
ObjectStorage
::
Concern
storage_options
Gitlab
.
config
.
packages
# TODO: Implement me
end
config/gitlab.yml.example
View file @
5ffae25a
...
...
@@ -207,6 +207,26 @@ production: &base
# endpoint: 'http://127.0.0.1:9000' # default: nil
# path_style: true # Use 'host/bucket_name/object' instead of 'bucket_name.host/object'
## Packages (maven repository so far)
packages:
enabled: true
# The location where build packages are stored (default: shared/packages).
# storage_path: shared/packages
object_store:
enabled: false
remote_directory: packages # The bucket name
# direct_upload: false # Use Object Storage directly for uploads instead of background uploads if enabled (Default: false)
# background_upload: false # Temporary option to limit automatic upload (Default: true)
# proxy_download: false # Passthrough all downloads via GitLab instead of using Redirects to Object Storage
connection:
provider: AWS
aws_access_key_id: AWS_ACCESS_KEY_ID
aws_secret_access_key: AWS_SECRET_ACCESS_KEY
region: us-east-1
# host: 'localhost' # default: s3.amazonaws.com
# endpoint: 'http://127.0.0.1:9000' # default: nil
# path_style: true # Use 'host/bucket_name/object' instead of 'bucket_name.host/object'
## GitLab Pages
pages:
enabled: false
...
...
config/initializers/1_settings.rb
View file @
5ffae25a
...
...
@@ -252,6 +252,24 @@ Settings.uploads['base_dir'] = Settings.uploads['base_dir'] || 'uploads/-/system
Settings
.
uploads
[
'object_store'
]
=
ObjectStoreSettings
.
parse
(
Settings
.
uploads
[
'object_store'
])
Settings
.
uploads
[
'object_store'
][
'remote_directory'
]
||=
'uploads'
#
# Packages
#
Settings
[
'packages'
]
||=
Settingslogic
.
new
({})
Settings
.
packages
[
'enabled'
]
=
true
if
Settings
.
packages
[
'enabled'
].
nil?
Settings
.
packages
[
'storage_path'
]
=
Settings
.
absolute
(
Settings
.
packages
[
'storage_path'
]
||
File
.
join
(
Settings
.
shared
[
'path'
],
"packages"
))
# Settings.artifact['path'] is deprecated, use `storage_path` instead
Settings
.
packages
[
'path'
]
=
Settings
.
packages
[
'storage_path'
]
Settings
.
packages
[
'max_size'
]
||=
100
# in megabytes
Settings
.
packages
[
'object_store'
]
||=
Settingslogic
.
new
({})
Settings
.
packages
[
'object_store'
][
'enabled'
]
=
false
if
Settings
.
packages
[
'object_store'
][
'enabled'
].
nil?
Settings
.
packages
[
'object_store'
][
'remote_directory'
]
||=
nil
Settings
.
packages
[
'object_store'
][
'direct_upload'
]
=
false
if
Settings
.
packages
[
'object_store'
][
'direct_upload'
].
nil?
Settings
.
packages
[
'object_store'
][
'background_upload'
]
=
true
if
Settings
.
packages
[
'object_store'
][
'background_upload'
].
nil?
Settings
.
packages
[
'object_store'
][
'proxy_download'
]
=
false
if
Settings
.
packages
[
'object_store'
][
'proxy_download'
].
nil?
# Convert upload connection settings to use string keys, to make Fog happy
Settings
.
packages
[
'object_store'
][
'connection'
]
&
.
deep_stringify_keys!
#
# 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