2018-11-19 21:01:13 -05:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2016-11-02 11:41:32 -04:00
|
|
|
module Gitlab
|
|
|
|
module Template
|
|
|
|
class DockerfileTemplate < BaseTemplate
|
2020-12-17 16:09:57 -05:00
|
|
|
def description
|
|
|
|
"# This file is a template, and might need editing before it works on your project."
|
2016-11-02 11:41:32 -04:00
|
|
|
end
|
|
|
|
|
|
|
|
class << self
|
|
|
|
def extension
|
2017-04-26 11:57:44 -04:00
|
|
|
'.Dockerfile'
|
2016-11-02 11:41:32 -04:00
|
|
|
end
|
|
|
|
|
|
|
|
def categories
|
|
|
|
{
|
|
|
|
"General" => ''
|
|
|
|
}
|
|
|
|
end
|
|
|
|
|
|
|
|
def base_dir
|
2017-04-26 11:57:44 -04:00
|
|
|
Rails.root.join('vendor/Dockerfile')
|
2016-11-02 11:41:32 -04:00
|
|
|
end
|
|
|
|
|
|
|
|
def finder(project = nil)
|
|
|
|
Gitlab::Template::Finders::GlobalTemplateFinder.new(self.base_dir, self.extension, self.categories)
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|