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
16248dc8
Commit
16248dc8
authored
Nov 23, 2018
by
Amit Rathi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Addressing review comments
parent
b82c9890
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
7 deletions
+9
-7
app/models/clusters/applications/cert_manager.rb
app/models/clusters/applications/cert_manager.rb
+8
-6
app/services/clusters/applications/create_service.rb
app/services/clusters/applications/create_service.rb
+1
-1
No files found.
app/models/clusters/applications/cert_manager.rb
View file @
16248dc8
...
@@ -39,18 +39,20 @@ module Clusters
...
@@ -39,18 +39,20 @@ module Clusters
def
cluster_issuer_file
def
cluster_issuer_file
{
{
'cluster_issuer.yaml'
:
cluster_issuer_
yaml_content
'cluster_issuer.yaml'
:
cluster_issuer_
content
.
deep_merge
(
cluster_issue_overlay
)
}
}
end
end
def
cluster_issuer_yaml_content
def
cluster_issuer_content
data
=
YAML
.
load_file
(
cluster_issuer_file_path
)
YAML
.
load_file
(
cluster_issuer_file_path
)
data
[
"spec"
][
"acme"
][
"email"
]
=
self
.
email
end
YAML
.
dump
(
data
)
def
cluster_issue_overlay
{
"spec"
=>
{
"acme"
=>
{
"email"
=>
self
.
email
}
}
}
end
end
def
cluster_issuer_file_path
def
cluster_issuer_file_path
"
#{
Rails
.
root
}
/vendor/cert_manager/cluster_issuer.yaml"
Rails
.
root
.
join
(
'vendor'
,
'cert_manager'
,
'cluster_issuer.yaml'
)
end
end
end
end
end
end
...
...
app/services/clusters/applications/create_service.rb
View file @
16248dc8
...
@@ -20,7 +20,7 @@ module Clusters
...
@@ -20,7 +20,7 @@ module Clusters
end
end
if
application
.
has_attribute?
(
:email
)
if
application
.
has_attribute?
(
:email
)
application
.
email
=
@
current_user
.
email
application
.
email
=
current_user
.
email
end
end
if
application
.
respond_to?
(
:oauth_application
)
if
application
.
respond_to?
(
:oauth_application
)
...
...
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