horticulturalist
Advanced tools
Comparing version 0.5.0 to 0.6.0
{ | ||
"name": "horticulturalist", | ||
"version": "0.5.0", | ||
"description": "", | ||
"version": "0.6.0", | ||
"description": "A fancy gardener", | ||
"main": "src/index.js", | ||
@@ -6,0 +6,0 @@ "bin": { |
@@ -19,3 +19,19 @@ Horticulturalist | ||
--bootstrap[=buildname] | ||
Download the latest master (or specified) build and deploy to the local db at startup. | ||
Pick one mode to run in: | ||
--local | ||
If you don't know which one you want, you want this one. For general | ||
local use. Deploys applications to a hidden directory in your home | ||
folder. | ||
--dev | ||
Runs horti in 'dev' mode, directly out of the given directory under a | ||
'temp' directory. For developers and for use while developing horti. | ||
--medic-os | ||
Only of interest to those who deploy using MedicOS. Deploys apps using | ||
the MedicOS' daemon. | ||
Additional options: | ||
--bootstrap[=buildname] | ||
Download the latest master (or specified) build and deploy to the | ||
local db at startup. |
#!/usr/bin/env node | ||
const Apps = require('./apps'); | ||
const chown = require('chown'); | ||
const decompress = require('decompress'); | ||
const fatality = require('./fatality'); | ||
const fs = require('fs-extra'); | ||
const info = require('./log').info; | ||
const lockfile = require('./lockfile'); | ||
const os = require('os'); | ||
const Path = require('path'); | ||
const redact = require('redact-basic-auth'); | ||
const trace = require('./log').trace; | ||
const parseArgs = require('minimist'); | ||
const chown = require('chown'), | ||
decompress = require('decompress'), | ||
fs = require('fs-extra'), | ||
os = require('os'), | ||
parseArgs = require('minimist'), | ||
path = require('path'), | ||
redact = require('redact-basic-auth'); | ||
const Apps = require('./apps'), | ||
fatality = require('./fatality'), | ||
help = require('./help'), | ||
info = require('./log').info, | ||
lockfile = require('./lockfile'), | ||
trace = require('./log').trace; | ||
// Include pouch in modular form or npm isn't happy | ||
@@ -23,2 +25,3 @@ const PouchDB = require('pouchdb-core'); | ||
development: { | ||
name: 'development', | ||
chown_apps: false, | ||
@@ -31,2 +34,3 @@ deployments: './temp/deployments', | ||
local: { | ||
name: 'local', | ||
chown_apps: false, | ||
@@ -39,2 +43,3 @@ deployments: `${os.homedir()}/.horticulturalist/deployments`, | ||
medic_os: { | ||
name: 'Medic OS', | ||
chown_apps: true, | ||
@@ -50,10 +55,16 @@ deployments: '/srv/software', | ||
if(argv.version) { | ||
const version = require('../package').version; | ||
console.log(`horticulturalist-${version}`); | ||
const mode = argv.dev ? MODES.development : | ||
argv.local ? MODES.local : | ||
argv['medic-os'] ? MODES.medic_os : | ||
undefined; | ||
if (argv.version || argv.v) { | ||
help.outputVersion(); | ||
return; | ||
} | ||
const mode = argv.dev ? MODES.development : | ||
argv.local ? MODES.local : MODES.medic_os; | ||
if (!mode || argv.help || argv.h) { | ||
help.outputHelp(); | ||
return; | ||
} | ||
@@ -80,3 +91,3 @@ let bootstrapDdoc = argv.bootstrap; | ||
info('Starting Horticulturalist'); | ||
info(`Starting Horticulturalist in ${mode.name} mode`); | ||
Promise.resolve() | ||
@@ -268,3 +279,3 @@ // If we're bootstrapping pull down the DDOC, process and deploy it | ||
identifier = identifier || app.digest.replace(/\//g, ''); | ||
return Path.resolve(Path.join(mode.deployments, app.name, identifier)); | ||
return path.resolve(path.join(mode.deployments, app.name, identifier)); | ||
}; | ||
@@ -271,0 +282,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
14675
13
361
37
1
4