Sha256: a420d7ec8f07019320a0d29da3eeee09c6ce5106dec461b2a23bfbfed54188e6

Contents?: true

Size: 531 Bytes

Versions: 21

Compression:

Stored size: 531 Bytes

Contents

class UpcaseSshFeature < ActiveRecord::Migration
  class FakeFeature < ActiveRecord::Base
    self.table_name = 'features'
  end

  def up
    f = FakeFeature.where(:name => 'Ssh').first
    f.update_attribute :name, 'SSH' if f.present?

    JobTemplate.where(:provider_type => 'Ssh').update_all("provider_type = 'SSH'")
  end

  def down
    f = FakeFeature.where(:name => 'SSH').first
    f.update_attribute :name, 'Ssh' if f.present?

    JobTemplate.where(:provider_type => 'SSH').update_all("provider_type = 'Ssh'")
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
foreman_remote_execution-1.3.7 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.3.6 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.4.1 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.3.5 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.3.4 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.3.3 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.3.2 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.3.1 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.3.0 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.2.2 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.2.1 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.2.0 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.1.1 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.1.0 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-1.0.0 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-0.3.2 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-0.3.1 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-0.3.0 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-0.2.3 db/migrate/20160111113032_upcase_ssh_feature.rb
foreman_remote_execution-0.2.2 db/migrate/20160111113032_upcase_ssh_feature.rb