add mysql support
This commit is contained in:
+1
-1
@@ -31,7 +31,7 @@ ENV BUNDLE_WITHOUT="development:test"
|
|||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
RUN apk add --no-cache build-base sqlite-dev libpq-dev vips-dev vips-poppler vips-heif libc6-compat ttf-freefont
|
RUN apk add --no-cache build-base sqlite-dev libpq-dev mariadb-dev vips-dev vips-poppler vips-heif libc6-compat ttf-freefont
|
||||||
|
|
||||||
COPY ./Gemfile ./Gemfile.lock ./
|
COPY ./Gemfile ./Gemfile.lock ./
|
||||||
|
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ gem 'google-cloud-storage'
|
|||||||
gem 'hexapdf'
|
gem 'hexapdf'
|
||||||
gem 'image_processing'
|
gem 'image_processing'
|
||||||
gem 'lograge'
|
gem 'lograge'
|
||||||
|
gem 'mysql2'
|
||||||
gem 'oj'
|
gem 'oj'
|
||||||
gem 'pagy'
|
gem 'pagy'
|
||||||
gem 'pg'
|
gem 'pg'
|
||||||
|
|||||||
@@ -286,6 +286,7 @@ GEM
|
|||||||
msgpack (1.7.1)
|
msgpack (1.7.1)
|
||||||
multi_json (1.15.0)
|
multi_json (1.15.0)
|
||||||
multipart-post (2.3.0)
|
multipart-post (2.3.0)
|
||||||
|
mysql2 (0.5.5)
|
||||||
net-http-persistent (4.0.2)
|
net-http-persistent (4.0.2)
|
||||||
connection_pool (~> 2.2)
|
connection_pool (~> 2.2)
|
||||||
net-imap (0.3.6)
|
net-imap (0.3.6)
|
||||||
@@ -507,6 +508,7 @@ DEPENDENCIES
|
|||||||
image_processing
|
image_processing
|
||||||
letter_opener_web
|
letter_opener_web
|
||||||
lograge
|
lograge
|
||||||
|
mysql2
|
||||||
oj
|
oj
|
||||||
pagy
|
pagy
|
||||||
pg
|
pg
|
||||||
|
|||||||
+3
-2
@@ -10,7 +10,8 @@ test:
|
|||||||
<<: *default
|
<<: *default
|
||||||
database: docuseal_test
|
database: docuseal_test
|
||||||
|
|
||||||
|
<% if ENV['DATABASE_URL'].to_s.empty? %>
|
||||||
production:
|
production:
|
||||||
adapter: <%= ENV['DATABASE_URL'].present? ? 'postgresql' : 'sqlite3' %>
|
adapter: sqlite3
|
||||||
encoding: unicode
|
|
||||||
database: <%= ENV['WORKDIR'] || '.' %>/db.sqlite3
|
database: <%= ENV['WORKDIR'] || '.' %>/db.sqlite3
|
||||||
|
<% end %>
|
||||||
|
|||||||
@@ -5,9 +5,9 @@ class CreateTemplates < ActiveRecord::Migration[7.0]
|
|||||||
create_table :templates do |t|
|
create_table :templates do |t|
|
||||||
t.string :slug, null: false, index: { unique: true }
|
t.string :slug, null: false, index: { unique: true }
|
||||||
t.string :name, null: false
|
t.string :name, null: false
|
||||||
t.string :schema, null: false
|
t.text :schema, null: false
|
||||||
t.string :fields, null: false
|
t.text :fields, null: false
|
||||||
t.string :submitters, null: false
|
t.text :submitters, null: false
|
||||||
|
|
||||||
t.references :author, null: false, foreign_key: { to_table: :users }, index: true
|
t.references :author, null: false, foreign_key: { to_table: :users }, index: true
|
||||||
t.references :account, null: false, foreign_key: true, index: true
|
t.references :account, null: false, foreign_key: true, index: true
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ class CreateSubmitters < ActiveRecord::Migration[7.0]
|
|||||||
t.string :uuid, null: false
|
t.string :uuid, null: false
|
||||||
t.string :email, null: false, index: true
|
t.string :email, null: false, index: true
|
||||||
t.string :slug, null: false, index: { unique: true }
|
t.string :slug, null: false, index: { unique: true }
|
||||||
t.string :values, null: false
|
t.text :values, null: false
|
||||||
t.string :ua
|
t.string :ua
|
||||||
t.string :ip
|
t.string :ip
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user