Commit Graph

277 Commits

Author SHA1 Message Date
ed83514a2f allow passing --drive to resin device init 2017-06-15 16:39:55 +03:00
a29b40eefa Move promise.spread to promise.join for clarity (from review) 2017-06-15 12:34:26 +02:00
df3c5ca07f Gzip while streaming, rather than gzipping the buffer up front
Connects-To: #549
2017-06-15 12:01:22 +02:00
e584dc43f7 Gzip images when uploading in resin deploy
Change-Type: minor
Connects-To: #549
2017-06-15 12:01:22 +02:00
90a5b15dbc Refactor docker stream buffering before start gzipping 2017-06-15 12:01:22 +02:00
37ec11bf25 Ensure emulated builds use the correct relative path to qemu
Change-Type: patch
Connects-To: #553
2017-06-14 20:50:24 +02:00
f2862f7fe2 Add emulated build option to resin build
This commit adds the ability to run a Docker build for an architecture
which is not the host architecture, using qemu-linux-user. Currently
this is only supported for linux.

Added:
* Installation of qemu which supports propagated execve flags
* Copying of qemu binary into the build context
* Transposing the given Dockerfile to use the qemu binary
* Intercepting of the build stream, so the output looks *almost* exactly
  the same.

Change-type: minor
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-06-14 12:06:03 +01:00
abc183a729 Change update check interval to once a day
This gives the user enough notice to stay well updated, but won't spam
them if they're using resin-cli frequently.

Connects-to: #485
Change-type: patch
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-05-23 17:29:23 -07:00
2d729a82a0 fix valid-email path 2017-05-20 00:19:31 +03:00
bc79832e1d resin ssh proxy support 2017-05-12 18:09:43 +03:00
654ec75598 Renamed build arg option to —buildArg/-B 2017-05-11 14:20:24 +03:00
66876a2c85 Add ability to specify built-time variables for local build
Change-Type: patch
2017-05-11 14:14:43 +03:00
404348f92e Highlight cache usage in resin build
This commit will highlight the usage of the cache when doing a docker
build via `resin build`, which not only helps the user understand what
the build is doing, but also achieves more parity with the cloud
builder.

Change-type: patch
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-05-04 14:09:23 +01:00
d249ac168a Fix the not-enough-unicorns bug
Add successful build indicator in the form of a unicorn.

Change-type: patch
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-05-04 13:18:25 +01:00
3ff5880ae3 Allow resin-cli deploy to also upload build logs if present
If build is ran through `resin deploy`, then logs will be stored and
uploaded to the database, where the dashboard can display them

Change-type: minor
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-05-04 13:11:50 +01:00
f50ae65560 Add cloud-builder builder output parity to build and deploy
Change-type: minor
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-04-25 13:13:11 +01:00
4fa1a9c1c6 Share nocache and tag build options between build and deploy
`resin build` had access to the `--nocache` and `--tag` options for
building with docker, but `resin deploy` did not. This commit adds the
options to the shared dockerUtils.appendOptions function.

Change-type: patch
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-04-24 20:05:18 +01:00
9050cb1975 Respect source parameter in resin build
Upon changing the name of the source parameter from `context`, some
places weren't changed, this commit fixes that.

Change-type: patch
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-04-24 16:41:15 +01:00
d3772386bf Add ability to build and deploy image locally using resin-cli
Using `resin build` a user can now build an image on their own docker
daemon. The daemon can be accessed via a local socket, a remote host and
a remote host over a TLS socket. Project type resolution is supported.
Nocache and tagging of images is also supported.

Using `resin deploy` a user can now deploy an image to their fleet. The
image can either be built by `resin-cli`, plain Docker, or from a remote
source.

Change-type: minor
Signed-off-by: Cameron Diver <cameron@resin.io>
2017-04-23 14:31:45 +01:00
77b30409bb update resin-device-init to pull in etcher-image-write 2017-03-28 14:37:13 +03:00
08b3db717e use individual methods promisification instead of promisifyAll 2017-03-27 12:14:55 +03:00
6cf32e445a isolate the sudo-runnable command 2017-03-27 11:43:35 +03:00
f940d7428c Point to forums instead of gitter
change-type: patch
2017-03-23 12:19:59 +02:00
b629ee6164 Move to preconfigured resin sdk 2017-01-25 19:33:43 +01:00
7a4de5357e Fix some issues with Resin-SDK usage after initial testing 2017-01-25 19:25:12 +01:00
f17cbb1205 use the new SDK factory 2017-01-25 19:25:12 +01:00
16a1741374 resin sync: always display device selection dialog when uuid is not passed as an argument
Closes #375
2016-09-15 13:09:25 +03:00
e0a2217b94 resin sync/ssh: always display selection dialog, even for a single online device
Closes #373
2016-09-15 13:09:25 +03:00
8b485b5ad5 Attempt to get device type from the image first partition
New images will ship a `device-type.json` file in the first partition,
which we can use instead of querying the API for certain configuration
and initialisation commands.

If the file is not found, or is malformed, we still fallback to the API.

Signed-off-by: Juan Cruz Viotti <jviotti@openmailbox.org>
2016-09-14 11:06:17 -07:00
68808e760e resin sync: filter out offline devices in interactive choosing dialog 2016-07-07 19:12:39 +03:00
4a05ce3f53 Attempt to infer the device uuid in resin sync
This PR adds functionality to `resin sync` to try to infer what the
device uuid is as follows:

- If the argument to `resin sync` is an app, get all the devices from
that application. If there is only one, auto-select it, otherwise show
an interactive drive selection widget.

- If the argument to `resin sync` is a uuid, use it directly, without
trying to infer anything.

- If no argument is passed to `resin sync`, display an interactive
selection widget showing all your devices from all your applications.

Signed-off-by: Juan Cruz Viotti <jviottidc@gmail.com>
2016-04-25 08:57:19 -04:00
c5692f8b13 Only throw "Invalid 2FA code" if we're sure that's the cause
Currently, such error will be thrown when
`resin.auth.twoFactor.challenge()` rejects, but an invalid code is not
the only thing this function can reject for.
2016-03-17 15:37:02 -04:00
30663b0301 Force update alert to be always shown
If `updateCheckInterval` has any meanginful value, the alert will be
shown one out of ten times, or something like that, making the user
likely to miss updates.

The underlying issue is that `update-notifier`, if it detects a cached
update notification, it deletes it, and only attempts to show it back if
`updateCheckInterval` is greater than `Date.now() - lastUpdateCheck`.
2016-03-08 09:23:03 -04:00
bee523828a Improve awaitDevice success message 2016-01-25 08:59:09 -04:00
4645ad06bc Redirect users to signup from login if they don't have an account 2016-01-13 00:25:31 -04:00
c3a5998d5c Reuse messages 2016-01-12 10:45:32 -04:00
78ab2af8ba Print verbose help in resin help command 2016-01-12 10:39:29 -04:00
8d709aea7d Implement purely interactive login command
The new login command interactively asks the user if he wants to login
using web/credentials/token.
2016-01-12 09:08:03 -04:00
70ea8dd1a3 Redirect users to GitHub and Gitter in case of errors
Users will ge a better experience by knowing exactly where to go for
help if things go wrong.
2016-01-12 08:31:40 -04:00
9cfce68489 Change license to Apache 2.0 2016-01-03 23:58:51 -04:00
abc8399260 Explain why we need the computer password on device init 2015-12-02 11:15:20 -04:00
e08c3752f9 Show device types when selecting applications
Some CLI commans prompt to select an existing application, presending a
dropdown with all the application names, however it's hard to remember
which application belon to which device type, which makes it easier to
select the wrong application.
2015-11-23 09:23:08 -04:00
c3b5a768e1 Handle Windows permissions elevation automatically 2015-11-12 13:30:48 -04:00
ba318f2939 Implement device move command
This command allows to user to move a device to another application he
owns.
2015-11-12 07:47:16 -04:00
c866f6e46c Use president to provide sudo functionality 2015-10-26 09:47:49 -04:00
de83a06db8 Clarify the need of computer password during sudo
Since we only prompt "Password:", it might be confusing for some users
that think they have to enter their Resin.io password instead.

Fixes: https://github.com/resin-io/resin-cli/issues/239
2015-10-26 08:49:41 -04:00
363f12f81b Refer to the correct waiting stream function
We recently changed to using `rindle`, however looks like we forgot
to replace this particular instance.
2015-10-26 08:34:07 -04:00
fc5fe6cf68 Fix validation module require typo 2015-10-21 13:28:51 -04:00
8fe08642f5 Merge pull request #245 from resin-io/jviotti/feature/simplify-quickstart
Remove project directory creation in quickstart
2015-10-21 13:20:35 -04:00
822632718f Merge pull request #247 from resin-io/jvioti/refactor/os
Remove unused getOperatingSystem function
2015-10-21 11:43:19 -04:00