Sha256: 16bb6a4e80005b175c799611d106a3c5677a2841d243b1300ea9d352172d31ed

Contents?: true

Size: 1.44 KB

Versions: 15

Compression:

Stored size: 1.44 KB

Contents

# frozen_string_literal: true

ActiveRecord::Schema.define(version: 0) do
  create_table :roles do |t|
    t.string :name, null: false
    t.timestamps null: false
  end

  create_table :permissions do |t|
    t.string :value, null: false
    t.belongs_to :role, null: false
    t.timestamps null: false
    t.index %i[role_id value], unique: true
  end

  create_table :api_subjects do |t|
    t.string :x509_cn, null: false
    t.string :contact_name, null: false
    t.string :contact_mail, null: false
    t.string :description, null: false
    t.boolean :enabled, null: false
    t.timestamps null: false
    t.index [:x509_cn], unique: true
  end

  create_table :api_subject_roles do |t|
    t.belongs_to :api_subject, null: false
    t.belongs_to :role, null: false
    t.timestamps null: false
  end

  create_table :subjects do |t|
    t.string :name, null: false
    t.string :mail, null: false
    t.string :targeted_id, null: false
    t.string :shared_token, null: false
    t.boolean :enabled, null: false
    t.boolean :complete, null: false
    t.timestamps null: false
  end

  create_table :subject_roles do |t|
    t.belongs_to :subject, null: false
    t.belongs_to :role, null: false
    t.timestamps null: false
  end

  add_foreign_key 'api_subject_roles', 'api_subjects'
  add_foreign_key 'api_subject_roles', 'roles'
  add_foreign_key 'permissions', 'roles'
  add_foreign_key 'subject_roles', 'roles'
  add_foreign_key 'subject_roles', 'subjects'
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
aaf-gumboot-2.6.3 spec/dummy/db/schema.rb
aaf-gumboot-2.6.2 spec/dummy/db/schema.rb
aaf-gumboot-2.6.1 spec/dummy/db/schema.rb
aaf-gumboot-2.6.0 spec/dummy/db/schema.rb
aaf-gumboot-2.5.1 spec/dummy/db/schema.rb
aaf-gumboot-2.5.0 spec/dummy/db/schema.rb
aaf-gumboot-2.4.0 spec/dummy/db/schema.rb
aaf-gumboot-2.2.0 spec/dummy/db/schema.rb
aaf-gumboot-2.1.4 spec/dummy/db/schema.rb
aaf-gumboot-2.1.3 spec/dummy/db/schema.rb
aaf-gumboot-2.1.1 spec/dummy/db/schema.rb
aaf-gumboot-2.1.0 spec/dummy/db/schema.rb
aaf-gumboot-2.0.1 spec/dummy/db/schema.rb
aaf-gumboot-1.2.0 spec/dummy/db/schema.rb
aaf-gumboot-1.1.0 spec/dummy/db/schema.rb