Commit 03b3fe13 authored by Kamil Trzcinski's avatar Kamil Trzcinski

Make images_enabled configurable

parent f41a3e24
...@@ -235,7 +235,8 @@ class ProjectsController < Projects::ApplicationController ...@@ -235,7 +235,8 @@ class ProjectsController < Projects::ApplicationController
def project_params def project_params
params.require(:project).permit( params.require(:project).permit(
:name, :path, :description, :issues_tracker, :tag_list, :runners_token, :name, :path, :description, :issues_tracker, :tag_list, :runners_token,
:issues_enabled, :merge_requests_enabled, :snippets_enabled, :issues_tracker_id, :default_branch, :issues_enabled, :merge_requests_enabled, :snippets_enabled, :images_enabled,
:issues_tracker_id, :default_branch,
:wiki_enabled, :visibility_level, :import_url, :last_activity_at, :namespace_id, :avatar, :wiki_enabled, :visibility_level, :import_url, :last_activity_at, :namespace_id, :avatar,
:builds_enabled, :build_allow_git_fetch, :build_timeout_in_minutes, :build_coverage_regex, :builds_enabled, :build_allow_git_fetch, :build_timeout_in_minutes, :build_coverage_regex,
:public_builds, :public_builds,
......
...@@ -84,6 +84,16 @@ ...@@ -84,6 +84,16 @@
%br %br
%span.descr Share code pastes with others out of git repository %span.descr Share code pastes with others out of git repository
- if Gitlab.config.registry.enabled
.form-group
.col-sm-offset-2.col-sm-10
.checkbox
= f.label :images_enabled do
= f.check_box :images_enabled
%strong Images
%br
%span.descr Use Docker Registry for this repository
= render 'builds_settings', f: f = render 'builds_settings', f: f
%fieldset.features %fieldset.features
......
...@@ -66,7 +66,8 @@ module API ...@@ -66,7 +66,8 @@ module API
expose :owner, using: Entities::UserBasic, unless: ->(project, options) { project.group } expose :owner, using: Entities::UserBasic, unless: ->(project, options) { project.group }
expose :name, :name_with_namespace expose :name, :name_with_namespace
expose :path, :path_with_namespace expose :path, :path_with_namespace
expose :issues_enabled, :merge_requests_enabled, :wiki_enabled, :builds_enabled, :snippets_enabled, :created_at, :last_activity_at expose :issues_enabled, :merge_requests_enabled, :wiki_enabled, :builds_enabled, :snippets_enabled, :images_enabled
expose :created_at, :last_activity_at
expose :shared_runners_enabled expose :shared_runners_enabled
expose :creator_id expose :creator_id
expose :namespace expose :namespace
......
...@@ -94,6 +94,7 @@ module API ...@@ -94,6 +94,7 @@ module API
# builds_enabled (optional) # builds_enabled (optional)
# wiki_enabled (optional) # wiki_enabled (optional)
# snippets_enabled (optional) # snippets_enabled (optional)
# images_enabled (optional)
# shared_runners_enabled (optional) # shared_runners_enabled (optional)
# namespace_id (optional) - defaults to user namespace # namespace_id (optional) - defaults to user namespace
# public (optional) - if true same as setting visibility_level = 20 # public (optional) - if true same as setting visibility_level = 20
...@@ -112,6 +113,7 @@ module API ...@@ -112,6 +113,7 @@ module API
:builds_enabled, :builds_enabled,
:wiki_enabled, :wiki_enabled,
:snippets_enabled, :snippets_enabled,
:images_enabled,
:shared_runners_enabled, :shared_runners_enabled,
:namespace_id, :namespace_id,
:public, :public,
...@@ -143,6 +145,7 @@ module API ...@@ -143,6 +145,7 @@ module API
# builds_enabled (optional) # builds_enabled (optional)
# wiki_enabled (optional) # wiki_enabled (optional)
# snippets_enabled (optional) # snippets_enabled (optional)
# images_enabled (optional)
# shared_runners_enabled (optional) # shared_runners_enabled (optional)
# public (optional) - if true same as setting visibility_level = 20 # public (optional) - if true same as setting visibility_level = 20
# visibility_level (optional) # visibility_level (optional)
...@@ -206,6 +209,7 @@ module API ...@@ -206,6 +209,7 @@ module API
# builds_enabled (optional) # builds_enabled (optional)
# wiki_enabled (optional) # wiki_enabled (optional)
# snippets_enabled (optional) # snippets_enabled (optional)
# images_enabled (optional)
# shared_runners_enabled (optional) # shared_runners_enabled (optional)
# public (optional) - if true same as setting visibility_level = 20 # public (optional) - if true same as setting visibility_level = 20
# visibility_level (optional) - visibility level of a project # visibility_level (optional) - visibility level of a project
...@@ -222,6 +226,7 @@ module API ...@@ -222,6 +226,7 @@ module API
:builds_enabled, :builds_enabled,
:wiki_enabled, :wiki_enabled,
:snippets_enabled, :snippets_enabled,
:images_enabled,
:shared_runners_enabled, :shared_runners_enabled,
:public, :public,
:visibility_level, :visibility_level,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment