diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 776351873ced31a3354cd264519e3ae1108de8ec..a8939b05e33ff2d46cbbcdea9cd7387d9e67ca2b 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -28,7 +28,6 @@ run_test_postgres:
     stage: test
     script:                
         - yarn install --frozen-lockfile --silent --non-interactive
-        - mv config/ci_test.yaml.example config/test.yaml
         - mv config/ci_postgres_test.env.example config/test.env
         - yarn test
         - yarn run lint
@@ -40,7 +39,6 @@ run_test_monet:
     stage: test
     script: 
         - yarn install --frozen-lockfile --silent --non-interactive
-        - mv config/ci_test.yaml.example config/test.yaml
         - mv config/ci_monet_test.env.example config/test.env
         - yarn test
         - yarn run lint
diff --git a/config/ci_monet_test.env.example b/config/ci_monet_test.env.example
index 2bec39d961d1f519f555b03c250283976fdc5a3b..bbdd0ca9838c9b3c69e69f58ff4d0af8d136c419 100644
--- a/config/ci_monet_test.env.example
+++ b/config/ci_monet_test.env.example
@@ -4,4 +4,5 @@ BLENDB_DB_PASSWORD=monetdb
 BLENDB_DB_HOST=monet
 BLENDB_DB_PORT=50000
 BLENDB_ADAPTER=monet
+BLENDB_SCHEMA_FILE=config/ci_test.yaml.example
 PORT=3000
diff --git a/config/ci_postgres_test.env.example b/config/ci_postgres_test.env.example
index 433eeb1292e090f1309b8d1bdad1873cf0df963a..64c1c5976c2e98b50fc42d2f223fa8fbbbfaf73f 100644
--- a/config/ci_postgres_test.env.example
+++ b/config/ci_postgres_test.env.example
@@ -4,4 +4,5 @@ BLENDB_DB_PASSWORD=
 BLENDB_DB_HOST=postgres
 BLENDB_DB_PORT=5432
 BLENDB_ADAPTER=postgres
+BLENDB_SCHEMA_FILE=config/ci_test.yaml.example
 PORT=3000
diff --git a/config/config.env.example b/config/config.env.example
index 565344bf4ef511a0bc4987e7f28dc99ed76535e1..16b7a86b31324c6cae552b0b3fc132e758bfeb88 100644
--- a/config/config.env.example
+++ b/config/config.env.example
@@ -4,4 +4,5 @@ BLENDB_DB_PASSWORD=secret
 BLENDB_DB_HOST=localhost
 BLENDB_DB_PORT=5432
 BLENDB_ADAPTER=postgres
+BLENDB_SCHEMA_FILE=config/config.yaml
 PORT=3000
diff --git a/src/adapter/postgres.spec.ts b/src/adapter/postgres.spec.ts
index 867d4c83a11326958b90e6f4f070b8430b3a40c4..a77952af864b6238603528e85c3fe05e97c5450f 100644
--- a/src/adapter/postgres.spec.ts
+++ b/src/adapter/postgres.spec.ts
@@ -36,7 +36,8 @@ describe("Sql adapter", () => {
     let fixture;
     before(function (done): void {
         // Arrow function not used to get acces to this and skip the test
-        config = ConfigParser.parse("config/test.yaml");
+        const configPath =  process.env.BLENDB_SCHEMA_FILE;
+        config = ConfigParser.parse(configPath);
 
         if (config.adapter === "postgres") {
             fixture = new FixPostgres(config.connection);
diff --git a/src/api/controllers/collect.spec.ts b/src/api/controllers/collect.spec.ts
index 24ac015abe395fbf93ed8b02be2545f9ee33d08c..7ad1619a03cfff39812ba0bd6f0e33ab7d61668e 100644
--- a/src/api/controllers/collect.spec.ts
+++ b/src/api/controllers/collect.spec.ts
@@ -36,7 +36,8 @@ describe("API collect controller", () => {
     let fixture;
     before(function (done): void {
         // Arrow function not used to get acces to this and skip the test
-        config = ConfigParser.parse("config/test.yaml");
+        const configPath =  process.env.BLENDB_SCHEMA_FILE;
+        config = ConfigParser.parse(configPath);
         if (config.adapter === "postgres") {
             fixture = new FixPostgres(config.connection);
             fixture.loadSource(config.sources, (err) => {
diff --git a/src/main.ts b/src/main.ts
index de792ba500918b67c978c0c1a3bc13716376eaa7..7a0133ff93671072e40bfbdc71f0652b8aa965c8 100755
--- a/src/main.ts
+++ b/src/main.ts
@@ -37,7 +37,7 @@ const app = module.exports = express();
 
 import { ConfigParser } from "./util/configParser";
 /** @hidden */
-const configPath = (app.get("env") === "test") ? "config/test.yaml" : "config/config.yaml";
+const configPath = process.env.BLENDB_SCHEMA_FILE;
 /** @hidden */
 const config = ConfigParser.parse(configPath);
 
diff --git a/test/scenario.ts b/test/scenario.ts
index 59a91b727ebcf6bda866c754c093360a6ba50251..8aa83ecb22e5142e59058afa9f9b4bf110b07da7 100644
--- a/test/scenario.ts
+++ b/test/scenario.ts
@@ -66,7 +66,8 @@ interface DataCtrlScenario {
     clausal: Query;
 }
 
-const config = ConfigParser.parse("config/test.yaml");
+const configPath =  process.env.BLENDB_SCHEMA_FILE;
+const config = ConfigParser.parse(configPath);
 
 const mets = config.metrics.sort((a, b) => {
     const aValue = parseInt(a.name.split(":")[1], 10);