debian-mirror-gitlab/debian/patches/0108-make-mysql-optional.patch
2017-09-10 18:21:32 +05:30

23 lines
701 B
Diff

From 85ec69dca3e07b27079efe1392574d7fb317186f Mon Sep 17 00:00:00 2001
From: Pirate Praveen <praveen@debian.org>
Date: Sat, 23 Jan 2016 10:14:15 -0500
Subject: [PATCH] allow specifying DB choice via ENV variable
---
Gemfile | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
--- a/Gemfile
+++ b/Gemfile
@@ -12,8 +12,9 @@
gem 'default_value_for', '~> 3.0'
# Supported DBs
-gem 'mysql2', '~> 0.4.5', group: :mysql
-gem 'pg', '~> 0.18.2', group: :postgres
+ENV["DB"] ||= "mysql"
+gem "mysql2", '~> 0.4.5' if ENV["DB"] == "all" || ENV["DB"] == "mysql"
+gem "pg", '~> 0.18.2' if ENV["DB"] == "all" || ENV["DB"] == "postgres"
gem 'rugged', '~> 0.26.0'
gem 'grape-route-helpers', '~> 2.0'