nukebase 2.3.0 → 2.5.0

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/README.md CHANGED
@@ -24,7 +24,7 @@ nukebase login --device only the code (SSH, a VM, no browser)
24
24
  nukebase accounts list signed-in accounts
25
25
  nukebase use you@x.com default for commands outside a project
26
26
  nukebase logout you@x.com sign out one account
27
- nukebase logout sign out every account
27
+ nukebase logout --all sign out every account
28
28
  ```
29
29
 
30
30
  Sign-ins are kept in `~/.nukebase/credentials.json`, never inside a project.
@@ -41,9 +41,14 @@ Push and pull carry it, so a fresh clone is already linked.
41
41
  ```
42
42
  nukebase create <name> [size] [email] sizes: 128mb, 256mb, 512mb, 1gb
43
43
  nukebase link <name> [email] connect a folder to an existing project
44
- nukebase push | pull | logs | rollback | backup | env push | domain | ...
44
+ nukebase push | pull | logs | rollback | backups | env push | domain | ...
45
45
  ```
46
46
 
47
+ Code moves with `push` / `pull`; the app's data (the `backup` paths in
48
+ `package.json`) only with `pull --data` / `push --data`. `rollback` undoes a
49
+ push from the push history kept on the server; `backups` lists the off-site
50
+ backups (every 4 hours, 30 days) and `backups restore <id>` puts one back.
51
+
47
52
  Run `nukebase help` for every command.
48
53
 
49
54
  ## CI
package/bin/nukebase.js CHANGED
@@ -24,6 +24,7 @@ if (!(args.has('version') && !args.command)) {
24
24
  const ACCOUNT_COMMANDS = ['login', 'logout', 'accounts', 'use', 'whoami', 'create', 'link'];
25
25
  const PROJECT_COMMANDS = [
26
26
  'push', 'pull', 'update', 'rollback', 'restorepoints', 'restore-points', 'backup', 'env',
27
+ 'restore', 'backups',
27
28
  'pause', 'restart', 'resume', 'delete', 'domain', 'logs', 'download',
28
29
  'regiontransfer', 'region-transfer'
29
30
  ];
@@ -47,7 +48,7 @@ Accounts
47
48
  login --email-link sign in with an emailed link instead
48
49
  login --password username + password (the master account)
49
50
  logout <email> sign out one account
50
- logout sign out every account on this machine
51
+ logout --all sign out every account on this machine
51
52
  accounts list signed-in accounts
52
53
  use <email> default account for commands outside a project
53
54
  whoami who owns this project, and are you signed in
@@ -61,33 +62,51 @@ New projects
61
62
  link <name> [email] connect this folder to an existing project
62
63
 
63
64
  In a project folder (runs as the account that owns the project)
65
+
66
+ Code
64
67
  push upload code and restart (--tier <size> if it has
65
68
  to create the project in this region)
66
- push --include backup ALSO upload the backup set, replacing the
67
- server's live data with your copy
68
69
  pull download code
69
- update refresh the NukeBase engine files
70
- backup [--out <dir>] download the backup set from the server
71
- backup --storage also the app's files in file storage (new or
72
- changed ones, straight from the storage)
73
- env push make the hosted environment (process.env) equal
74
- to ./.env, then restart the project
75
- env list [--show] variable names set on the server
70
+ update update the NukeBase ENGINE files in this project
71
+ (the CLI itself updates with npm i -g nukebase)
72
+ download [--out f.zip] the whole project as a ZIP, as the server has it
73
+
74
+ Data (the paths listed under "backup" in package.json)
75
+ pull --data [--out <dir>] download the live data to this machine, the
76
+ files in file storage too when listed; only new
77
+ or changed files, nothing local is deleted
78
+ push --data replace the server's live data with your copy
79
+ (stops the app first; nothing there is deleted)
80
+
81
+ Push history (one restore point per push, kept on the server)
76
82
  rollback [id] undo a push. Live data is kept.
77
- rollback backup [id] undo a push AND restore the backup set as it was
78
- then; discards writes since
79
- rollback list show restore points (also: restorepoints)
83
+ rollback [id] --data also put the data back as it was then; discards
84
+ every write since
85
+ rollback list show the push history
86
+
87
+ Backups (off-site, every 4 hours, kept 30 days; projects with file storage)
88
+ backups list them
89
+ backups restore <id> put one back (--code-only / --data-only); what it
90
+ replaces is saved to the push history first
91
+ backups download <id> its database into ./server/data, or everything
92
+ with --out <dir>
93
+
94
+ Running
80
95
  pause stop the project (base fee + disk still accrue)
81
- restart | resume restart it; also resumes a paused project
96
+ restart restart it; also resumes a paused project
97
+ logs [--follow] recent log output; --follow streams
82
98
  delete delete it on the server; asks for the name
99
+
100
+ Settings
101
+ env push make the hosted environment (process.env) equal
102
+ to ./.env, then restart the project
103
+ env list [--show] variable names set on the server
83
104
  domain connect a custom domain, step by step
84
105
  domain <name> [--email e] connect in one go (DNS already set)
85
106
  domain remove disconnect the custom domain
86
107
  domain email send the app's emails from the custom domain
87
108
  (--root | --sub, --wait)
88
109
  domain email remove go back to sending from nukebase.com
89
- logs [--follow] recent log output; --follow streams
90
- download [--out f.zip] the project ZIP, exactly as the server has it
91
110
  regiontransfer [region] move this project to another region, step by step
92
111
  regiontransfer --to <email> ... into a different account on the target
93
112
 
@@ -97,7 +116,12 @@ Options
97
116
  --as <email> with --region: as another signed-in account
98
117
  --yes, -y non-interactive (no y/n prompts)
99
118
  --no-check push even if server-side .js files don't parse
100
- --streams <1-8> parallel connections for big push/pull/backup
119
+ --streams <1-8> parallel connections for big push/pull
120
+
121
+ Older names still work: backup (pull --data), push --include backup
122
+ (push --data), rollback backup <id> (rollback <id> --data), restorepoints
123
+ (rollback list), restore (backups restore), backup --from (backups download),
124
+ resume (restart).
101
125
 
102
126
  CI: set NUKEBASE_TOKEN and NUKEBASE_UID (create a build token on the
103
127
  dashboard under Signed-in devices).