Sha256: dc96f06a6c41ba25e99235d687ed235119266024e897864c0f0e0d18fe185fad

Contents?: true

Size: 398 Bytes

Versions: 42

Compression:

Stored size: 398 Bytes

Contents

module ForemanVirtWhoConfigure
  class Cleaner
    def clean_up!
      User.as_anonymous_admin do
        remove_configurations
        remove_hidden_auth_sources
      end
    end

    private

    def remove_hidden_auth_sources
      AuthSourceHiddenWithAuthentication.destroy_all
    end

    # also removes service users
    def remove_configurations
      Config.destroy_all
    end
  end
end

Version data entries

42 entries across 42 versions & 1 rubygems

Version Path
foreman_virt_who_configure-0.5.25 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.24 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.23 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.21 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.20 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.19 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.18 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.17 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.16 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.15 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.14 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.13 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.12 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.11 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.10 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.9 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.8 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.7 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.6 app/services/foreman_virt_who_configure/cleaner.rb
foreman_virt_who_configure-0.5.5 app/services/foreman_virt_who_configure/cleaner.rb