Paulo Castro
a25a52c21b
Error handling: add ExpectedError type as alternative to exitWithExpectedError()
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-11-12 19:36:43 +00:00
Paulo Castro
b69ba0b617
Improve command usage format consistency in 'balena help' output
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-11-10 00:54:22 +00:00
Cameron Diver
b31e253fa4
Support optional containers when pushing to local target
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-11-06 10:30:28 +00:00
Cameron Diver
62b7d2fd1a
Use all available on-device images during local push
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-11-04 10:27:35 +00:00
Cameron Diver
55b2b5a467
Fix potentialy undefined build task when livepushing
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-10-28 17:50:02 +00:00
Cameron Diver
8ed4f547e0
Update livepush to support build arguments
...
Change-type: minor
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-10-22 13:24:00 +01:00
Thodoris Greasidis
96bc8a829e
Fix missing code formatting
...
Signed-off-by: Thodoris Greasidis <thodoris@balena.io>
2019-10-16 15:47:05 +03:00
Thodoris Greasidis
1b943bdf7d
Support managing tags using release commit hashes
...
The sdk version in the shrinkwrap already
supports setting tags by commit hashes and as a
result this already works in the cli as of v11.9.6.
This PR just adds some docs and some extra
handling when the commit param prefix is all
numeric.
Resolves : #1064
Change-type: minor
Signed-off-by: Thodoris Greasidis <thodoris@balena.io>
2019-10-16 09:12:17 +03:00
Paulo Castro
05cb89725e
Fix privilege elevation (sudo) for 'os initialize', 'join', 'leave'
...
* sudo shell arguments required escaping for 'os initialize'
* sudo was not working for standalone zip packages (incorrect
Node.js path in argv[0])
* Interactive 'join' and 'leave' not working on Windows because
'windosu' does not capture stderr.
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-10-15 21:47:26 +01:00
Cameron Diver
0c5ed7adfb
Support container contracts when pushing to local devices
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-10-14 17:18:56 +01:00
Paulo Castro
e0e76a1aa8
Avoid stack trace and Sentry report if user answers No to confirmation prompts
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-10-10 16:02:41 +01:00
Paulo Castro
7dd33adfd1
Fix 'balena build --emulated' on Windows (including default docker socket)
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-10-09 13:10:49 +01:00
Cameron Diver
7a865b2e15
Send all debug output to stderr
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-09-19 13:25:40 +01:00
Paulo Castro
2ff427fb90
Refactor oclif integration and preparser
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-09-17 17:20:16 +01:00
Thodoris Greasidis
87004621ce
Support balena join
to applications of compatible architectures
...
Resolves : #1431
Change-type: minor
Signed-off-by: Thodoris Greasidis <thodoris@balena.io>
2019-09-16 21:31:07 +03:00
Paulo Castro
6631fb5a69
Mitigate "MaxListenersExceededWarning" by reusing Logger instance
...
The full warning output was:
(node:43572) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added. Use emitter.setMaxListeners() to increase limit
(node:43572) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 error listeners added. Use emitter.setMaxListeners() to increase limit
(node:43572) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 close listeners added. Use emitter.setMaxListeners() to increase limit
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-09-12 01:49:40 +01:00
Paulo Castro
f76ca1804a
Update balena-sdk from 11.18.0 to 12.10.0 (pre-req for #1153 and #1304 )
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-09-11 16:08:30 +01:00
Paulo Castro
d484c957bb
Detect Docker Desktop (Docker for Mac) and warn about architecture emulation
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-09-11 12:05:07 +01:00
Matthew McGinn
e3435c66df
logging: note that tarring is occurring
...
As noted in #1411 , this tarring can be particularly expensive so cluing
in the user may help alleviate pain
Connects-to: #1411
Change-type: patch
Signed-off-by: Matthew McGinn <matthew@balena.io>
2019-08-28 20:37:50 +02:00
Paulo Castro
19c3178062
Enable emulated builds on remote devices running a different OS as the CLI
...
E.g. "balena build -e -h <IP> -p 2375" with the CLI running on a Mac laptop,
using balenaEngine on an Intel NUC device, building an image for the RPi (ARM
image arch). Previously, QEMU setup by the CLI assumed that docker ran on the
same OS as the CLI (Docker for Mac has built-in binfmt_misc support and does
not require additional setup, but balenaEngine on Linux requires explicit QEMU
setup.)
Change-type: minor
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-08-22 13:37:07 +01:00
Paulo Castro
516fa90a20
Fix SecretRemovalError (balena build) when docker daemon arch != target arch
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-08-21 22:25:18 +01:00
Paulo Castro
cdedc58ec1
Fix failing registry secrets authentication under certain conditions
...
('balena build' and 'balena deploy')
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-08-19 16:41:59 +01:00
Lucian
f1d9c29786
Fix bug where "env rm" fails silently if an additional arg is present
...
Fixes #1380
Argument parsing of "env rm" command was improved by migrating it to oclif
Change-type: patch
Signed-off-by: Lucian <lucian.buzzo@gmail.com>
2019-08-12 13:47:31 +01:00
Cameron Diver
67a4e88e44
Support headless remote builds
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-08-06 08:45:05 +01:00
Matthew McGinn
d92e076829
chore: fix up small typos, remove gitter link
...
Change-type: patch
Signed-off-by: Matthew McGinn <matthew@balena.io>
2019-07-17 20:12:52 +01:00
Paulo Castro
225408c57d
Add "build secrets" and "build variables" support for push/build/deploy
...
to/on/via balena devices
Change-type: minor
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-07-15 16:23:35 +01:00
Paulo Castro
8cfacc9cbc
Fix truncated logs in local multicontainer image builds (balena build/deploy)
...
Resolves : #1346
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-07-15 16:19:41 +01:00
Paulo Castro
49a7eb30c0
Remove BETA suffix from Windows and macOS installers, and update INSTALL.md
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-07-15 14:08:27 +01:00
Michel Wohlert
9eae9dcee3
Add os.sshKeys to generateBaseConfig
...
Change-type: minor
2019-07-09 14:01:58 +02:00
Paulo Castro
9d5ecb5f9c
Add options to 'balena version' to show Node.js version
...
Change-type: minor
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-06-27 16:22:26 +01:00
Thodoris Greasidis
f095ac169a
patterns: Add debug logs in the getOnlineTargetUuid resolution
...
Change-type: patch
Signed-off-by: Thodoris Greasidis <thodoris@balena.io>
2019-06-26 13:44:56 +03:00
Cameron Diver
36026d8556
Fix using an image more than once in a balena push
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-20 16:46:29 +01:00
Cameron Diver
3b09c5ac91
Remove the livepush initialisation double printed log
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-20 15:20:19 +01:00
Cameron Diver
c3e5147a19
Fix output of seperation newline during livepush
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-18 11:45:12 +01:00
Cameron Diver
cf9fdbe6e4
If a secrets file is not specified, read it from the data directory
...
Change-type: minor
Closes : #1164
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-18 11:13:09 +01:00
Cameron Diver
ea43130135
livepush: Ignore the .git directory when performing a livepush
...
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-12 12:41:46 +01:00
Thodoris Greasidis
825213c02a
Add device OS update action
...
Resolves : #788
Depends-on: https://github.com/balena-io/balena-sdk/pull/638
Change-type: minor
Signed-off-by: Thodoris Greasidis <thodoris@balena.io>
2019-06-11 15:27:23 +03:00
Cameron Diver
8b5ebe0645
Pin prettier and add formatting changes
...
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-10 11:07:51 +01:00
Cameron Diver
24e49bf131
Cancel ongoing livepushes when a new change occurs
...
Also fix livepush logging when a new container is created (previously
the logs of the commands would stop working after this has happened)
Change-type: minor
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-07 15:59:27 +01:00
Paulo Castro
d8c942c77e
Fix "catch-uncommitted" build failure (npm run prettify)
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-06-07 01:30:32 +01:00
Rich Bayliss
5d137f3c20
fix: Add single code path to get full, online-only device UUIDs
...
Both the tunnel and SSH commands require a full UUID for an online
device. A single code path was added to provide this, taking either
an application name or a partial UUID as a search parameter.
In the event of an application name being provided, a device select
form is presented to the user to pick from the online devices at that
time.
Change-type: patch
Signed-off-by: Rich Bayliss <rich@balena.io>
2019-06-06 17:05:08 +01:00
Thodoris Greasidis
051268168a
Add initial typings for resin-cli-form
...
Change-type: patch
Signed-off-by: Thodoris Greasidis <thodoris@balena.io>
2019-06-06 16:21:35 +03:00
Cameron Diver
6696b1b5f7
Make livepush the default when pushing to a local device
...
Change-type: major
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-04 13:52:36 +01:00
Cameron Diver
b391c96e64
Allow multiple services to be tailed with balena logs and push
...
Also correctly type the input.
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-04 13:52:35 +01:00
Cameron Diver
94c9e13106
Fix windows straight-to-container SSH
...
Closes : #1211
Change-type: patch
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-04 13:51:58 +01:00
Cameron Diver
64c2f00d2a
Update balena ssh command to support local devices and multicontainer
...
Change-type: major
Signed-off-by: Cameron Diver <cameron@balena.io>
2019-06-04 13:51:57 +01:00
Paulo Castro
8f8d6b5f08
Sort 'balena help' primary commands in manually specified order
...
Connects-to: #1140
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-06-04 13:51:57 +01:00
Paulo Castro
abf573fa47
Begin the transition to oclif with 'balena env add' (fix dropped leading
...
zero in device UUID).
This commit is fairly chunky because it adds the oclif dependency for
the first time, and refactors the CLI help and docs generation code to
accommodate both Capitano and oclif.
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-06-04 13:51:56 +01:00
Paulo Castro
13e3e5e8ea
Bump min Node.js version to 8.0, ts-node to 8.1 and typescript to 3.4.
...
Refactor typings folder for use with the tsconfig typeRoots option.
Change-type: major
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-06-04 13:51:55 +01:00
Paulo Castro
e145540132
Allow newline characters in build/deploy --buildArg values
...
Change-type: patch
Signed-off-by: Paulo Castro <paulo@balena.io>
2019-05-30 15:03:56 +01:00