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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
645c8651
Commit
645c8651
authored
Jun 12, 2017
by
Tomasz Maczukin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove Gitlab::Ci::Config::Entry::DockerImage
parent
3e75fd6c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
34 deletions
+23
-34
lib/gitlab/ci/config/entry/docker_image.rb
lib/gitlab/ci/config/entry/docker_image.rb
+0
-31
lib/gitlab/ci/config/entry/image.rb
lib/gitlab/ci/config/entry/image.rb
+22
-1
lib/gitlab/ci/config/entry/service.rb
lib/gitlab/ci/config/entry/service.rb
+1
-2
No files found.
lib/gitlab/ci/config/entry/docker_image.rb
deleted
100644 → 0
View file @
3e75fd6c
module
Gitlab
module
Ci
class
Config
module
Entry
module
DockerImage
def
hash?
@config
.
is_a?
(
Hash
)
end
def
string?
@config
.
is_a?
(
String
)
end
def
name
value
[
:name
]
end
def
entrypoint
value
[
:entrypoint
]
end
def
value
return
{
name:
@config
}
if
string?
return
@config
if
hash
?
{}
end
end
end
end
end
end
lib/gitlab/ci/config/entry/image.rb
View file @
645c8651
...
...
@@ -7,7 +7,6 @@ module Gitlab
#
class
Image
<
Node
include
Validatable
include
DockerImage
ALLOWED_KEYS
=
%i[name entrypoint]
.
freeze
...
...
@@ -18,6 +17,28 @@ module Gitlab
validates
:name
,
type:
String
,
presence:
true
validates
:entrypoint
,
type:
String
,
allow_nil:
true
end
def
hash?
@config
.
is_a?
(
Hash
)
end
def
string?
@config
.
is_a?
(
String
)
end
def
name
value
[
:name
]
end
def
entrypoint
value
[
:entrypoint
]
end
def
value
return
{
name:
@config
}
if
string?
return
@config
if
hash
?
{}
end
end
end
end
...
...
lib/gitlab/ci/config/entry/service.rb
View file @
645c8651
...
...
@@ -5,9 +5,8 @@ module Gitlab
##
# Entry that represents a configuration of Docker service.
#
class
Service
<
Nod
e
class
Service
<
Imag
e
include
Validatable
include
DockerImage
ALLOWED_KEYS
=
%i[name entrypoint command alias]
.
freeze
...
...
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