summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorKamil Trzciński <ayufan@ayufan.eu>2018-11-23 15:24:32 +0000
committerKamil Trzciński <ayufan@ayufan.eu>2018-11-23 15:24:32 +0000
commit9c98e2a9226c5ee0787b2f36c253eef6a03ecb7b (patch)
treea328247746bf4497f0b540028497276ff3226d22 /db
parent52ca66fc54f15641104a8ccc9232baeb7d1f53a1 (diff)
parentc3041b7f7c4b407f1d32ac2f7ab1e21812b40694 (diff)
downloadgitlab-ce-9c98e2a9226c5ee0787b2f36c253eef6a03ecb7b.tar.gz
Merge branch 'certmanager-temp' into 'master'
Deploy cert-manager to managed cluster for SSL certificates See merge request gitlab-org/gitlab-ce!23036
Diffstat (limited to 'db')
-rw-r--r--db/migrate/20181101191341_create_clusters_applications_cert_manager.rb19
-rw-r--r--db/schema.rb12
2 files changed, 31 insertions, 0 deletions
diff --git a/db/migrate/20181101191341_create_clusters_applications_cert_manager.rb b/db/migrate/20181101191341_create_clusters_applications_cert_manager.rb
new file mode 100644
index 00000000000..4966b89964a
--- /dev/null
+++ b/db/migrate/20181101191341_create_clusters_applications_cert_manager.rb
@@ -0,0 +1,19 @@
+# frozen_string_literal: true
+
+class CreateClustersApplicationsCertManager < ActiveRecord::Migration
+ include Gitlab::Database::MigrationHelpers
+
+ DOWNTIME = false
+
+ def change
+ create_table :clusters_applications_cert_managers do |t|
+ t.references :cluster, null: false, index: false, foreign_key: { on_delete: :cascade }
+ t.integer :status, null: false
+ t.string :version, null: false
+ t.string :email, null: false
+ t.timestamps_with_timezone null: false
+ t.text :status_reason
+ t.index :cluster_id, unique: true
+ end
+ end
+end
diff --git a/db/schema.rb b/db/schema.rb
index cc47368c530..1fdc417b639 100644
--- a/db/schema.rb
+++ b/db/schema.rb
@@ -640,6 +640,17 @@ ActiveRecord::Schema.define(version: 20181112103239) do
t.index ["user_id"], name: "index_clusters_on_user_id", using: :btree
end
+ create_table "clusters_applications_cert_managers", force: :cascade do |t|
+ t.integer "cluster_id", null: false
+ t.integer "status", null: false
+ t.string "version", null: false
+ t.string "email", null: false
+ t.datetime_with_timezone "created_at", null: false
+ t.datetime_with_timezone "updated_at", null: false
+ t.text "status_reason"
+ t.index ["cluster_id"], name: "index_clusters_applications_cert_managers_on_cluster_id", unique: true, using: :btree
+ end
+
create_table "clusters_applications_helm", force: :cascade do |t|
t.integer "cluster_id", null: false
t.datetime_with_timezone "created_at", null: false
@@ -2288,6 +2299,7 @@ ActiveRecord::Schema.define(version: 20181112103239) do
add_foreign_key "cluster_projects", "projects", on_delete: :cascade
add_foreign_key "cluster_providers_gcp", "clusters", on_delete: :cascade
add_foreign_key "clusters", "users", on_delete: :nullify
+ add_foreign_key "clusters_applications_cert_managers", "clusters", on_delete: :cascade
add_foreign_key "clusters_applications_helm", "clusters", on_delete: :cascade
add_foreign_key "clusters_applications_ingress", "clusters", name: "fk_753a7b41c1", on_delete: :cascade
add_foreign_key "clusters_applications_jupyter", "clusters", on_delete: :cascade