Files
archived-hc-harbor/db/migrate/20250312160326_create_project_repo_mappings.rb
2025-03-12 12:15:14 -04:00

14 lines
379 B
Ruby

class CreateProjectRepoMappings < ActiveRecord::Migration[8.0]
def change
create_table :project_repo_mappings do |t|
t.references :user, null: false, foreign_key: true
t.string :project_name, null: false
t.string :repo_url, null: false
t.timestamps
end
add_index :project_repo_mappings, [ :user_id, :project_name ], unique: true
end
end