theforeman/foreman

View on GitHub
app/services/foreman/template_snapshot_service.rb

Summary

Maintainability
B
4 hrs
Test Coverage

Class TemplateSnapshotService has 30 methods (exceeds 20 allowed). Consider refactoring.
Open

  class TemplateSnapshotService
    TEMPLATES_DIRECTORY = Rails.root.join('app', 'views', 'unattended', 'provisioning_templates')

    def self.templates
      new.templates
Severity: Minor
Found in app/services/foreman/template_snapshot_service.rb - About 3 hrs to fix

    Method define_host_params has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        def define_host_params(host)
          host_params = {
            "enable-epel" => "true",
            "package_upgrade" => "true",
            "ansible_tower_provisioning" => "true",
    Severity: Minor
    Found in app/services/foreman/template_snapshot_service.rb - About 1 hr to fix

      There are no issues that match your filters.

      Category
      Status