From 9b253c91826fea65516008da704e0728b7ca3bc6 Mon Sep 17 00:00:00 2001 From: Leonard Smith Date: Thu, 8 Apr 2021 14:24:03 -0500 Subject: [PATCH] Add a staging environment --- config/deploy.js | 13 ++++++++++++- config/environment.js | 7 +++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/config/deploy.js b/config/deploy.js index 6fc6416..17a8945 100644 --- a/config/deploy.js +++ b/config/deploy.js @@ -13,8 +13,19 @@ module.exports = function(deployTarget) { } if (deployTarget === 'staging') { - ENV.build.environment = 'production'; + ENV.build.environment = 'staging'; // configure other plugins for staging deploy target here + ENV['simply-ssh'] = { + connection: { + // parameter hash accepted by SSH2, see https://github.com/mscdex/ssh2 for details + host: process.env.SSH_HOST, + port: process.env.SSH_PORT, + username: process.env.SSH_USER, + privateKey: process.env.SSH_KEY + }, + dir: '/home/onlin401/public_html/allgreektome/frontend/test/', + keep: 5 + } } if (deployTarget === 'production') { diff --git a/config/environment.js b/config/environment.js index dc9bdc3..29ac3b8 100644 --- a/config/environment.js +++ b/config/environment.js @@ -58,5 +58,12 @@ module.exports = function (environment) { ENV.APP.hostUrl = 'http://backend.bibletranslationresources.org'; } + if (environment === 'staging') { + ENV.APP.hostUrl = 'http://backend.bibletranslationresources.org'; + ENV.APP.rootURL = 'http://bibletranslationresources.org/test/current/'; + ENV.APP.baseUrl = 'http://bibletranslationresources.org/test/current/'; + ENV.APP.locationType = 'hash'; + } + return ENV; };