cob-cli 2.35.1 → 2.35.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commands/init.js +7 -1
- package/package.json +1 -1
package/lib/commands/init.js
CHANGED
|
@@ -4,6 +4,8 @@ const { newProjectTasks } = require("../task_lists/init_newProject");
|
|
|
4
4
|
const fs = require('fs-extra');
|
|
5
5
|
const axios = require('axios');
|
|
6
6
|
const git = require('simple-git');
|
|
7
|
+
const https = require('https');
|
|
8
|
+
|
|
7
9
|
|
|
8
10
|
/* ******************************** MAIN LOGIC **************************************** */
|
|
9
11
|
async function init(servername,args) {
|
|
@@ -55,7 +57,11 @@ async function notInsideGitRepo() {
|
|
|
55
57
|
async function validCobServer(server) {
|
|
56
58
|
var result;
|
|
57
59
|
try {
|
|
58
|
-
|
|
60
|
+
// At request level
|
|
61
|
+
const agent = new https.Agent({
|
|
62
|
+
rejectUnauthorized: false
|
|
63
|
+
});
|
|
64
|
+
result = await axios.get("https://"+server+"/health", { httpsAgent: agent })
|
|
59
65
|
} catch {}
|
|
60
66
|
|
|
61
67
|
if(result && result.status == "200") return true
|
package/package.json
CHANGED