A lightly modified copy of Mastodon, the canonical repository for Chinwag Social's live code. https://social.chinwag.org/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

schema.rb 3.9KB

  1. # encoding: UTF-8
  2. # This file is auto-generated from the current state of the database. Instead
  3. # of editing this file, please use the migrations feature of Active Record to
  4. # incrementally modify your database, and then regenerate this schema definition.
  5. #
  6. # Note that this schema.rb definition is the authoritative source for your
  7. # database schema. If you need to create the application database on another
  8. # system, you should be using db:schema:load, not running all the migrations
  9. # from scratch. The latter is a flawed and unsustainable approach (the more migrations
  10. # you'll amass, the slower it'll run and the greater likelihood for issues).
  11. #
  12. # It's strongly recommended that you check this file into your version control system.
  13. ActiveRecord::Schema.define(version: 20160224223247) do
  14. # These are extensions that must be enabled in order to support this database
  15. enable_extension "plpgsql"
  16. create_table "accounts", force: :cascade do |t|
  17. t.string "username", default: "", null: false
  18. t.string "domain"
  19. t.string "verify_token", default: "", null: false
  20. t.string "secret", default: "", null: false
  21. t.text "private_key"
  22. t.text "public_key", default: "", null: false
  23. t.string "remote_url", default: "", null: false
  24. t.string "salmon_url", default: "", null: false
  25. t.string "hub_url", default: "", null: false
  26. t.datetime "created_at", null: false
  27. t.datetime "updated_at", null: false
  28. t.text "note", default: "", null: false
  29. t.string "display_name", default: "", null: false
  30. t.string "uri", default: "", null: false
  31. t.string "url"
  32. end
  33. add_index "accounts", ["username", "domain"], name: "index_accounts_on_username_and_domain", unique: true, using: :btree
  34. create_table "favourites", force: :cascade do |t|
  35. t.integer "account_id", null: false
  36. t.integer "status_id", null: false
  37. t.datetime "created_at", null: false
  38. t.datetime "updated_at", null: false
  39. end
  40. add_index "favourites", ["account_id", "status_id"], name: "index_favourites_on_account_id_and_status_id", unique: true, using: :btree
  41. create_table "follows", force: :cascade do |t|
  42. t.integer "account_id", null: false
  43. t.integer "target_account_id", null: false
  44. t.datetime "created_at", null: false
  45. t.datetime "updated_at", null: false
  46. end
  47. add_index "follows", ["account_id", "target_account_id"], name: "index_follows_on_account_id_and_target_account_id", unique: true, using: :btree
  48. create_table "mentions", force: :cascade do |t|
  49. t.integer "account_id"
  50. t.integer "status_id"
  51. t.datetime "created_at", null: false
  52. t.datetime "updated_at", null: false
  53. end
  54. add_index "mentions", ["account_id", "status_id"], name: "index_mentions_on_account_id_and_status_id", unique: true, using: :btree
  55. create_table "statuses", force: :cascade do |t|
  56. t.string "uri"
  57. t.integer "account_id", null: false
  58. t.text "text", default: "", null: false
  59. t.datetime "created_at", null: false
  60. t.datetime "updated_at", null: false
  61. t.integer "in_reply_to_id"
  62. t.integer "reblog_of_id"
  63. t.string "url"
  64. end
  65. add_index "statuses", ["uri"], name: "index_statuses_on_uri", unique: true, using: :btree
  66. create_table "stream_entries", force: :cascade do |t|
  67. t.integer "account_id"
  68. t.integer "activity_id"
  69. t.string "activity_type"
  70. t.datetime "created_at", null: false
  71. t.datetime "updated_at", null: false
  72. end
  73. create_table "users", force: :cascade do |t|
  74. t.string "email", default: "", null: false
  75. t.integer "account_id", null: false
  76. t.datetime "created_at", null: false
  77. t.datetime "updated_at", null: false
  78. end
  79. add_index "users", ["email"], name: "index_users_on_email", unique: true, using: :btree
  80. end