20230830100819_create_ssl_certificates.rb 732 B

12345678910111213141516171819
  1. # Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. class CreateSSLCertificates < ActiveRecord::Migration[6.1]
  3. def change
  4. # return if it's a new setup
  5. return if !Setting.exists?(name: 'system_init_done')
  6. create_table :ssl_certificates do |t|
  7. t.string :fingerprint, limit: 250, null: false
  8. t.binary :certificate, limit: 10.megabytes, null: false
  9. t.string :subject, limit: 250, null: false
  10. t.datetime :not_before, limit: 3, null: false
  11. t.datetime :not_after, limit: 3, null: false
  12. t.boolean :ca, default: false, null: false
  13. t.timestamps limit: 3, null: false
  14. end
  15. end
  16. end