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
81b5c7fc
Commit
81b5c7fc
authored
Mar 27, 2020
by
Tomasz Maczukin
Committed by
Kamil Trzciński
Mar 27, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Configure additional rails hosts with env variable
parent
06fee04e
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
0 deletions
+10
-0
changelogs/unreleased/configure-additional-rails-hosts-with-env-variable.yml
...ed/configure-additional-rails-hosts-with-env-variable.yml
+5
-0
config/initializers/rails_host_authorization.rb
config/initializers/rails_host_authorization.rb
+5
-0
No files found.
changelogs/unreleased/configure-additional-rails-hosts-with-env-variable.yml
0 → 100644
View file @
81b5c7fc
---
title
:
Add possibility to conigure additional rails hosts with env variable
merge_request
:
28133
author
:
type
:
other
config/initializers/rails_host_authorization.rb
View file @
81b5c7fc
...
@@ -4,4 +4,9 @@
...
@@ -4,4 +4,9 @@
if
Rails
.
env
.
development?
if
Rails
.
env
.
development?
Rails
.
application
.
config
.
hosts
+=
[
Gitlab
.
config
.
gitlab
.
host
,
'unix'
]
Rails
.
application
.
config
.
hosts
+=
[
Gitlab
.
config
.
gitlab
.
host
,
'unix'
]
if
ENV
[
'RAILS_HOSTS'
]
additional_hosts
=
ENV
[
'RAILS_HOSTS'
].
split
(
','
).
select
(
&
:presence
)
Rails
.
application
.
config
.
hosts
+=
additional_hosts
end
end
end
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