Sha256: d476c0676e6e14eb67e44b19e6aa7111b6e8792fe2d08e8782b620aaac2482e4

Contents?: true

Size: 559 Bytes

Versions: 32

Compression:

Stored size: 559 Bytes

Contents

class CreateHostgroupsPuppetclasses < ActiveRecord::Migration[6.0]
  def up
    # this table is later renamed into hostgroup_classes and thus we don't want to create it if it exists under the later name
    return if table_exists?(:hostgroups_puppetclasses) || table_exists?(:hostgroup_classes)
    create_table :hostgroups_puppetclasses, id: false do |t|
      t.references :hostgroup, foreign_key: true, null: false
      t.references :puppetclass, foreign_key: true, null: false
    end
  end

  def down
    drop_table :hostgroups_puppetclasses
  end
end

Version data entries

32 entries across 32 versions & 1 rubygems

Version Path
foreman_puppet-8.0.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-6.4.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-7.0.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-6.3.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-6.2.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-6.1.1 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-5.1.3 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-6.1.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-6.0.1 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-6.0.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-5.1.2 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-4.1.1 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-5.1.1 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-5.1.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-4.1.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-4.0.4 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-5.0.0 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-4.0.3 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-4.0.2 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb
foreman_puppet-3.0.7 db/migrate_foreman/20090905150132_create_hostgroups_puppetclasses.foreman_puppet.rb