Class: Dependabot::Docker::FileUpdater
Constant Summary
collapse
- YAML_REGEXP =
/^[^\.].*\.ya?ml$/i
- DOCKER_REGEXP =
/(docker|container)file/i
- FROM_REGEX =
/FROM(\s+--platform\=\S+)?/i
Class Method Summary
collapse
Instance Method Summary
collapse
#updated_dependency_files
Class Method Details
.updated_files_regex ⇒ Object
19
20
21
|
# File 'lib/dependabot/docker/file_updater.rb', line 19
def self.updated_files_regex
[DOCKER_REGEXP, YAML_REGEXP]
end
|
Instance Method Details
#container_image_regex ⇒ Object
34
35
36
|
# File 'lib/dependabot/docker/file_updater.rb', line 34
def container_image_regex
%r{^#{FROM_REGEX}\s+(docker\.io/)?}o
end
|
#file_type ⇒ Object
24
25
26
|
# File 'lib/dependabot/docker/file_updater.rb', line 24
def file_type
"Dockerfile or Containerfile"
end
|
#yaml_file_pattern ⇒ Object
29
30
31
|
# File 'lib/dependabot/docker/file_updater.rb', line 29
def yaml_file_pattern
YAML_REGEXP
end
|