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
1ac1f1f6
Commit
1ac1f1f6
authored
Jun 17, 2019
by
Imre Farkas
Committed by
Douwe Maan
Jun 17, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CE port of IP address restriction for groups
parent
63043b6f
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
28 additions
and
0 deletions
+28
-0
app/views/groups/settings/_permissions.html.haml
app/views/groups/settings/_permissions.html.haml
+1
-0
db/migrate/20190514105711_create_ip_restriction.rb
db/migrate/20190514105711_create_ip_restriction.rb
+20
-0
db/schema.rb
db/schema.rb
+7
-0
No files found.
app/views/groups/settings/_permissions.html.haml
View file @
1ac1f1f6
...
...
@@ -17,6 +17,7 @@
%br
%span
.descr.text-muted
=
share_with_group_lock_help_text
(
@group
)
=
render_if_exists
'groups/settings/ip_restriction'
,
f:
f
,
group:
@group
=
render
'groups/settings/lfs'
,
f:
f
=
render
'groups/settings/project_creation_level'
,
f:
f
,
group:
@group
=
render
'groups/settings/two_factor_auth'
,
f:
f
...
...
db/migrate/20190514105711_create_ip_restriction.rb
0 → 100644
View file @
1ac1f1f6
# frozen_string_literal: true
class
CreateIpRestriction
<
ActiveRecord
::
Migration
[
5.1
]
include
Gitlab
::
Database
::
MigrationHelpers
DOWNTIME
=
false
def
change
create_table
:ip_restrictions
do
|
t
|
t
.
references
:group
,
references: :namespace
,
column: :group_id
,
type: :integer
,
null:
false
,
index:
true
t
.
string
:range
,
null:
false
end
add_foreign_key
(
:ip_restrictions
,
:namespaces
,
column: :group_id
,
on_delete: :cascade
)
# rubocop: disable Migration/AddConcurrentForeignKey
end
end
db/schema.rb
View file @
1ac1f1f6
...
...
@@ -1051,6 +1051,12 @@ ActiveRecord::Schema.define(version: 20190611161641) do
t
.
index
[
"usage"
,
"project_id"
],
name:
"index_internal_ids_on_usage_and_project_id"
,
unique:
true
,
where:
"(project_id IS NOT NULL)"
,
using: :btree
end
create_table
"ip_restrictions"
,
force: :cascade
do
|
t
|
t
.
integer
"group_id"
,
null:
false
t
.
string
"range"
,
null:
false
t
.
index
[
"group_id"
],
name:
"index_ip_restrictions_on_group_id"
,
using: :btree
end
create_table
"issue_assignees"
,
id:
false
,
force: :cascade
do
|
t
|
t
.
integer
"user_id"
,
null:
false
t
.
integer
"issue_id"
,
null:
false
...
...
@@ -2565,6 +2571,7 @@ ActiveRecord::Schema.define(version: 20190611161641) do
add_foreign_key
"import_export_uploads"
,
"projects"
,
on_delete: :cascade
add_foreign_key
"internal_ids"
,
"namespaces"
,
name:
"fk_162941d509"
,
on_delete: :cascade
add_foreign_key
"internal_ids"
,
"projects"
,
on_delete: :cascade
add_foreign_key
"ip_restrictions"
,
"namespaces"
,
column:
"group_id"
,
on_delete: :cascade
add_foreign_key
"issue_assignees"
,
"issues"
,
name:
"fk_b7d881734a"
,
on_delete: :cascade
add_foreign_key
"issue_assignees"
,
"users"
,
name:
"fk_5e0c8d9154"
,
on_delete: :cascade
add_foreign_key
"issue_metrics"
,
"issues"
,
on_delete: :cascade
...
...
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