From b3a216e1978daf79a919ca7fd1d86076de4a46ac Mon Sep 17 00:00:00 2001 From: Joel Hayhurst Date: Tue, 25 Feb 2020 01:09:36 -0800 Subject: [PATCH] Run rails db:setup in Dockerfile Running rails db:migrate causes problems with older migrations which are broken by newer code. Also update db/schema.rb to the latest one generated by running rails db:migrate. --- Dockerfile | 3 +-- db/schema.rb | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 7b695103..36b7b7d4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,5 +5,4 @@ RUN apt-get update -qq && \ COPY . /notebook-ai WORKDIR /notebook-ai RUN bundle install -RUN rake db:create -RUN rake db:migrate +RUN rails db:setup diff --git a/db/schema.rb b/db/schema.rb index d323ca09..4b15fa95 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -1368,7 +1368,7 @@ ActiveRecord::Schema.define(version: 2020_01_30_224044) do t.datetime "updated_at", null: false t.string "src_file_name" t.string "src_content_type" - t.bigint "src_file_size" + t.integer "src_file_size" t.datetime "src_updated_at" t.index ["content_type", "content_id"], name: "index_image_uploads_on_content_type_and_content_id" t.index ["user_id"], name: "index_image_uploads_on_user_id"